Why is global-styles an embed and not in the site settings code?

I had added some css stylings to the global-styles embed because I had some additional custom css code that was needed on every page of the website.

It then occurred to me that I now had to update this embed on every page of my website.

Wouldn’t it make more sense to put all the globally required css code that is in global-styles into the section of custom code in the site settings? This way when you need to update something or add more css code that is needed on global components, it is updated for every page of the website.

Just checking I’m not missing something about this embed because someone at Finsweet decided it was optimal to have these styles on an html embed element rather than in site settings and I’d love to understand the reasoning behind that choice before I go changing things in my projects.

Thanks for any help!

Hi @rory15stevens !

That’s a good point, we decided to keep the Global Styles as a component/symbol on all pages because when you add the CSS snippets in an embed code, you can already see the updates in the designer canvas.

You can add the code in the project settings if you rather, but you will only see the changes when you publish the website. That’s the main reason.



Riiiiiiight, yeah I didn’t think about that. Thanks Eve!

1 Like