0

I'm building a browser extension and I want to use bootstrap in it. Problem is the bootstrap css is colliding with the page's css messing up some websites.

Is there a way to separate the content script css from the web page's css? Is there some known solution to this?

K41F4r
  • 1,443
  • 1
  • 16
  • 36
  • Possible duplicate of [How to really isolate stylesheets in the Google Chrome extension?](https://stackoverflow.com/questions/12783217/how-to-really-isolate-stylesheets-in-the-google-chrome-extension) – wOxxOm Mar 26 '19 at 15:18

1 Answers1

2

You can provide a namespaced version of bootstrap, where global styles are not applied outside a namespace CSS selector.

For generating this you must build bootstrap yourself using SASS.

This answer is a good resume of the procedure: How to namespace Twitter Bootstrap so styles don't conflict

keul
  • 7,673
  • 20
  • 45