This package has been deprecated

Author message:

The package moved into the '@undercut' scope. Please visit the https://undercut.js.org for updated package names or any additional information.

undercut

0.4.0 • Public • Published

✂ undercut ✂

JavaScript data processing pipelines and utilities. Use native Iterators/Generators/Observers like it's 2015 already.

  • Based on existing JS protocols and language features
  • Balanced API: not too imperative, not too functional
  • Easy operation extensibility and composability
  • Pure ES Modules with Node 12 loader compliance
  • Raw code in packages (compile in place)
  • Lazy evaluation when possible
  • Tree shaking friendliness
  • 90% test coverage
  • SemVer

Installation

npm install --save undercut
# or 
yarn add undercut

undercut provides raw Stage 4 ECMAScript code in the package, don't forget to include its node_modules directories into Babel config or another compiler of your choice.

Usage

Please check GitHub for more detailed readme.

import { pull, filter, map, skip, toArray } from "undercut";
 
const source = [1, 2, 3, 4, 5, 6, 7];
 
const result = pull(toArray, [
    skip(2),
    filter(x => x % 3 === 0),
    map(x => x * 2) // Will be executed only 3 times.
], source);
 
console.log(result); // [8, 10, 14]

License

Licensed under the MIT License, see LICENSE for more information.

Package Sidebar

Install

npm i undercut

Weekly Downloads

1

Version

0.4.0

License

MIT

Unpacked Size

62.6 kB

Total Files

97

Last publish

Collaborators

  • spyke