easy-glob

1.1.2 • Public • Published

Build Status

easy-glob

simple and easy to use glob with instant results using fast-glob as backend and is faster than node-glob.

Usage

Node

const glob = require('easy-glob');

// async / await
const res = await glob.read('./*.js');
console.log(res); // ['file1.js', 'file2.js']

// sync
const syncRes = glob.readSync('./*.js');
console.log(syncRes); // ['file1.js', 'file2.js']

// promise
glob.read('./*.js')
  .then(result => console.log(result)) // ['file1.js', 'file2.js']

CLI

$ glob <pattern> [options]
$ glob read <pattern> [options]
$ glob readSync <pattern> [options]

# Examples
$ glob "./*"
$ glob "./**/*.js, src/"

Package Sidebar

Install

npm i easy-glob

Weekly Downloads

1

Version

1.1.2

License

MIT

Unpacked Size

7.61 kB

Total Files

20

Last publish

Collaborators

  • soenkekluth