Can I prevent CSS from loading in the content script? #122
Unanswered
wallw-teal
asked this question in
Q&A
Replies: 1 comment 6 replies
-
It should only include a CSS file in your manifest's content script if you import the CSS file into the content script at some point. Are you including an HTML file in the plugin's If you could share a small reproduction, I could give you better advice. But yeah, it seems like you're importing the CSS when you shouldn't be. |
Beta Was this translation helpful? Give feedback.
6 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I have a content script which needs to just load its JS, and then a portion of it will add an iframe to the page and subsequently load the styles only inside that iframe (which are imported into app and sub-component definitions directly). Currently, the build correctly spits out
dist/style.css
and I have it entered inweb_accessible_resources
, but the resultingdist/manifest.json
gets the following:which leaks styles expected to be contained by the iframe onto the whole page. Is there a way to avoid including the
"css"
entry there?Beta Was this translation helpful? Give feedback.
All reactions