Skip to content

Is it possible to force darkmode layout on component ? #966

Discussion options

You must be logged in to vote

@joffreypersia Have you tried a wrapping <div> around the component markup that you wish to display in 'dark mode'? e.g.:

<div class="dark">
    ...
</div>

The Tailwind CSS docs indicate this should work:

...they will be applied whenever the dark class is present earlier in the HTML tree.

Replies: 1 comment 3 replies

Comment options

You must be logged in to vote
3 replies
@igmltd
Comment options

@joffreypersia
Comment options

@jeffchown
Comment options

Answer selected by joffreypersia
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
3 participants