Skip to content

Latest commit

 

History

History
45 lines (31 loc) · 640 Bytes

README.md

File metadata and controls

45 lines (31 loc) · 640 Bytes

NOT MAINTAINED mongodb-pipeline-factory

Generate MongoDB pipelines with ease. Save dozens of keystrokes.

Features

  • Faster overviews
  • pipeline validation
  • lightweight library
  • 100 % test coverage

Installation

$ npm install mongodb-pipeline-factory --save

Usage

Import the stages or operators you need first.

import { cond, gt, project } from 'mongodb-pipeline-factory'

Now build your first pipeline.

project(
  ['item', 1],
  ['discount', cond(
    gt('$quantity', 250),
    30,
    20
  )]
)

Author

Julian Claus and contributors.

License

MIT