Irina Glushko 2389e7160b HW1 done | 3 年之前 | |
---|---|---|
.. | ||
index.js | 3 年之前 | |
license | 3 年之前 | |
package.json | 3 年之前 | |
readme.md | 3 年之前 |
A regular expression for file paths that contain a
node_modules
folder.
$ npm install --save node-modules-regexp
const nodeModules = require('node-modules-regexp');
nodeModules.test('/foo/node_modules/bar.js');
//=> true
nodeModules.test('/foo/bar.js');
//=> false
The returned value is a regular expression, soooo.....
MIT © James Talmage