next-theme
Answered
Iridescent shark posted this in #help-forum
Iridescent sharkOP
How to apply next-theme class to <body> instead of <html>?
Answered by Iridescent shark
I fixed it by overriding blueprintjs css styles in
globals.css, thank you for help11 Replies
Why do you want to do so?
Iridescent sharkOP
I'm using blueprintjs components which dark theme works by adding
.bp5-dark to the container. If class is added to the <html> some components don't change theme.Iridescent sharkOP
ok, then I need to write my own
Maybe...
Does using body give you the correct results?
Does using body give you the correct results?
The way i see it, its mostly a problem with how blueprintjs handles their theming.
One way around this might be to use the
https://github.com/pacocoursey/next-themes?tab=readme-ov-file#avoid-hydration-mismatch
useTheme hook. Do with that what you will:https://github.com/pacocoursey/next-themes?tab=readme-ov-file#avoid-hydration-mismatch
Iridescent sharkOP
I fixed it by overriding blueprintjs css styles in
globals.css, thank you for helpAnswer