Dynamically loading CSS/SCSS files #12282
Unanswered
ofilipowicz
asked this question in
Help
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
I have a Bootstrap theme that supports a dark mode. It's done by loading one of the two .scss files - normal theme.scss or theme-dark.scss. I'd like to import one of them dynamically in _app.tsx based on the Context API variable. Although I'm not sure if there is a way to do it in Next.js, I can just import stylesheets unconditionally.
Beta Was this translation helpful? Give feedback.
All reactions