Awesome
scope-styles-injectify
Browserify transform to automatically inject the scoped css from scope-styles into the page
CLI usage
browserify -t [ scope-styles-extractify --runtime=true ] main.js
API usage
var browserify = require('browserify');
var extractify = require('scoped-styles-extractify');
var b = browserify('./main.js');
b.transform(extractify, {runtime: false});
b.bundle();
options
- runtime Boolean, default is
false
- Whether scope-styles should evaluate style objects at runtime (in browser) or at buildtime.
- If
false
, the style object is evaluated at buildtime and the code to inject the css is inlined. - If
true
, scope-styles is merely replaced with scope-styles-inject.