Created
January 21, 2016 11:45
-
-
Save SystemZ/b98aabf23233642e15f8 to your computer and use it in GitHub Desktop.
Prefix bootstrap to prevent conflicts in wordpress plugin
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
https://formden.com/blog/isolate-bootstrap | |
sudo npm install less -g | |
prefix.less | |
.superbootstart { | |
@import (less) 'bootstrap.css'; | |
@import (less) 'bootstrap-theme.css'; /* optional */ | |
} | |
lessc prefix.less superbootstart.css | |
superbootstart.css | |
replace: | |
.superbootstart body | |
and | |
.superbootstart html | |
to | |
.superbootstart | |
then use it like this | |
<div class="superbootstart"> | |
<div class="btn btn-primary">Test button</div> | |
</div> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment