How to implement an SVG logo in Studio Theme?

How to implement an SVG logo in Studio Theme?

benjams
Visitor
1 0 0

Hello, I'm trying to implement an SVG logo header on my client's website (that I built using the Studio Theme) and I'm trying to identify which portion of the code I need to target to make this happen. Is there a specific code string to use to swap it with?

 

I was using this tutorial, however this is for a different theme so it doesn't have the same code. 

 

Any help is very much appreciated.

Reply 1 (1)

Tristram
Shopify Partner
90 12 22

Hey mate, swapping out the logo with svg can be a little problematic if you're not careful with how you implement it. 

In the case of Studio, there are two places, you're looking for the "if" block approx line 377 with the section.settings.logo and approx line 495. 
You'll effectively want to replace the entire if block with the svg.

I'd recommend still using a png or jpg logo in the section settings as that logo is also used in the head for the logo in your company schema.

DigitalConsultant.xyz