Comparing version 2.0.3 to 2.0.5
{ | ||
"name": "derequire", | ||
"version": "2.0.3", | ||
"version": "2.0.5", | ||
"description": "remove requires", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
@@ -8,2 +8,6 @@ derequire [![Build Status](https://travis-ci.org/calvinmetcalf/derequire.svg)](https://travis-ci.org/calvinmetcalf/derequire) | ||
`derequire` can be used either as a JavaScript API or as a CLI. | ||
### JavaScript API | ||
```javascript | ||
@@ -32,1 +36,13 @@ var derequire = require('derequire'); | ||
__Note:__ In order to avoid quite a few headaches the token you're changing from and the token you're changing to need to be the same length. | ||
### Command-line API | ||
There's a CLI that accepts a file path as an argument (absolute or relative to CWD) or reads from `stdin` if file path is `-` or omitted, and accepts `-f|--from` and `-t|--to` options that correspond to the API `tokenFrom` and `tokenTo` options. Examples: | ||
```bash | ||
derequire input.js > output.js | ||
derequire < input.js > output.js | ||
browserify input.js | derequire > output.js | ||
browserify input.js | derequire - > output.js | ||
derequire input.js --from require --to _gonzo_ > output.js | ||
``` |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
6811
6
47