HUGO

Is there any way to accomplish Dark theme toggle for syntax highlighting using Chroma?

I want to be able to toggle my syntax highlighting theme on the push of a button, say from Monokai to Github.
One method I’ve thought of is classifying the body as .dark when dark mode is set and having separate styles for .dark pre and .dark code.
Is it possible to do so statically?

I think this is more related to css(or scss) than Hugo.
I accomplish theming by following this article

This theming strategy is applied hugo-theme-zzo

1 Like

The things is, I want Hugo to generate two chroma styles as CSS separately. That’s what I was doubtful of.