How to control CSS load order?

How to control CSS load order?

  

I am adding a link to a stylesheet with the "AddStylesheetTag" Action. I noticed that this puts the link tag before any of the link tags for the Web Block. However, in my use case, I need it to override the CSS in the Web Blocks. So... what are my choices to get this to load after the CSS from the Web Blocks? Is this a time to use jQuery or JavaScript? I really, REALLY do not want to inject the styles directly into the page, it is a big sheet and caching needs to be my friend here...

Thanks!

J.Ja

Hi Justin,

The order of the stylesheets, afaik, is the following:

1. AddStylesheetTag
2. Webblock
3. Root Theme, (and other parents)
4. Current Theme
5. Screen
6. Inline

You can try to include your CSS in the Current Theme or try to include at the end of the body using JQuery

Kind regards,

Remco Dekkinga

Remco -

Thanks! this is about what it looked like to me as well. JQuery it is! This is dynamically generated CSS.

J.Ja