@effet/core

0.2.0 • Public • Published

@effet/core

Core package. Use this with others to enhance your effects.

API

Table of Contents

construct

This is the main juice of the library. This function behaves similarily to pipe - it is a variadic function that accepts operators as arguments.

Parameters

  • operators ...any

Returns Chain

Chain

construct returns this instance for convinience.

extend

Creates a new effect chain (based on this one), but allows you to extend it with additional operators.

Parameters
  • operators ...[Operator] An array of operators to extend the chain.

Returns Chain New, separate instance of Chain.

Operators

This is a list of operators that are available in the core package.

source

This operator sets the input data for the effect to an arbitrary value.

Parameters
  • input any A value that will become the new input data

Returns Operator An instance of this operator

project

Assuming the output is an object or an array of objects, project filters the resulting properties based on the array of allowed keys.

Parameters

  • keys [String] An array of keys that will be present in the resulting object.

Readme

Keywords

none

Package Sidebar

Install

npm i @effet/core

Weekly Downloads

1

Version

0.2.0

License

MIT

Unpacked Size

16.2 kB

Total Files

5

Last publish

Collaborators

  • are