Skip to content

Commit 9462b27

Browse files
committed
changed --css to -o | --output
1 parent 0fbe0a7 commit 9462b27

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ Read Mark Dalgleish's excellent ["End of Global CSS"](https://medium.com/seek-ui
1414

1515
First install the package: `npm install --save css-modulesify`
1616

17-
Then you can use it as a browserify plugin, eg: `browserify -p [ css-modulesify --css dist/main.css ] example/index.js`
17+
Then you can use it as a browserify plugin, eg: `browserify -p [ css-modulesify -o dist/main.css ] example/index.js`
1818

1919
Inside `example/index.js` you can now load css into your scripts. When you do `var box1 = require('./box1.css')`, `box1` will be an object to lookup the localized classname for one of the selectors in that file.
2020

@@ -25,7 +25,7 @@ var styles = require('./styles.css');
2525
var div = `<div class="${styles.inner}">...</div>`;
2626
```
2727

28-
The generated css will contain locally-scoped versions of any css you have `require`'d, and will be written out to the file you specify in the `--css` option.
28+
The generated css will contain locally-scoped versions of any css you have `require`'d, and will be written out to the file you specify in the `--output` or `-o` option.
2929

3030
## Example
3131

index.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,9 @@ var cssExt = /\.css$/;
77
module.exports = function (browserify, options) {
88
options = options || {};
99

10-
var cssOutFilename = options.css;
10+
var cssOutFilename = options.output || options.o;
1111
if (!cssOutFilename) {
12-
throw new Error('css-modulesify needs the --css option (path to output css file)');
12+
throw new Error('css-modulesify needs the --output / -o option (path to output css file)');
1313
}
1414

1515
var cssOut = through();

0 commit comments

Comments
 (0)