simple-glob-observable

1.0.2 • Public • Published

glob-observable

A Simple Observable interface over node-glob.

Example

Install

npm install simple-glob-observable
const fs = require('fs')
const glob = require('simple-glob-observable')
const { map } = require('rxjs/operators/map')
const { max } = require('rxjs/operators/max')
 
glob('./**', { ignore: 'node_modules/**' })
  .pipe(
    map(p => ({ size: fs.statSync(p).size, path: p })),
    max((x, y) => x.size > y.size)
  )
  .subscribe(c => console.log('max size file:', c.path))

Usage

glob(pattern, [options])

Options

sync: perform a synchronous glob search, default is false.

see node-glob for more details.

Versions

Current Tags

  • Version
    Downloads (Last 7 Days)
    • Tag
  • 1.0.2
    2
    • latest

Version History

  • Version
    Downloads (Last 7 Days)
    • Published
  • 1.0.2
    2
  • 1.0.1
    1

Package Sidebar

Install

npm i simple-glob-observable

Weekly Downloads

3

Version

1.0.2

License

MIT

Last publish

Collaborators

  • jinahm