Skip to content

Defining "root" element #10991

Answered by jackall3n
jackall3n asked this question in Help
Apr 12, 2023 · 2 comments · 8 replies
Discussion options

You must be logged in to vote

Although postcss-scopify did help me in this situation, I wanted a bit more control.

So I created a postcss plugin called postcss-scope.

It allows you to scope an entire css file, including the tailwind directives. But it also allows you to specify files to ignore & allows you to override the selector per file.

This is useful in my case because I'm developing a Chrome extension that injects a component into existing pages, but also has an extension popup and it's own page. In this case I was able to allow tailwind to reset styles globally.

Replies: 2 comments 8 replies

Comment options

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

@wongjn
Comment options

@jackall3n
Comment options

Comment options

You must be logged in to vote
5 replies
@sametcodes
Comment options

@jackall3n
Comment options

@sametcodes
Comment options

@jackall3n
Comment options

@reciosonny
Comment options

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