I have an existing website and the client requires a new page that uses a different colour scheme and different coloured logo. Layout and navigation would remain the same.
A bit of background…
My CSS is stored in a series of chunks that get compiled into a static .css file.
So I have chunks such as [[$col-primary]], [[$col-secondary]], [[$col-alert]] etc. The chunks just contain hex codes. I then have aa series of chunk in which these colours are used.
It works really well but I’m just wondering about handling this one separate page. Is another context the way to go?
I don’t think a separate context helps.
Another context is more helpful when you want to share chunks/snippets between 2 different websites (as chunks/snippets are not context-specific). It sounds more like you want to achieve the exact opposite.
I would put a snippet on that page that would do nothing if it’s not that page ID (return "";). If it is is that page ID, it would use regClientCSS() or one of its siblings is to inject the new, overriding CSS, below the rest of the page’s CSS.