Package Exports
- matched
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (matched) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
matched

Adds array support to node-glob, sync and async. Also supports tilde expansion (user home) and resolving to global npm modules.
(TOC generated by verb using markdown-toc)
Install
Install with npm:
$ npm i matched --save
TODO
- async
- sync
- promise
- n/a stream - use [glob-stream][] for streams support
Usage
var glob = require('matched');
async
glob(['*.js'], function(err, files) {
//=> ['utils.js', 'index.js']
});
sync
var files = glob.sync(['*.js']);
//=> ['utils.js', 'index.js']
promise
glob.promise(['*.txt'])
.then(function(files) {
//=> ['a.txt', 'b.txt', 'c.txt']
});
options
All methods take options as the second argument:
glob(['*.js'], {cwd: 'test'}, function(err, files) {
//=> ['test.js']
});
Related projects
- is-glob: Returns
true
if the given string looks like a glob pattern or an extglob pattern.… more | homepage - look-up: Faster drop-in replacement for find-up and findup-sync. | homepage
- micromatch: Glob matching for javascript/node.js. A drop-in replacement and faster alternative to minimatch and multimatch. Just… more | homepage
Running tests
Install dev dependencies:
$ npm i -d && npm test
Contributing
Pull requests and stars are always welcome. For bugs and feature requests, please create an issue.
Author
Jon Schlinkert
License
Copyright © 2015 Jon Schlinkert Released under the MIT license.
This file was generated by verb on December 27, 2015.