pipe-into

Typescript implementation of the pipe pattern

Usage no npm install needed!

<script type="module">
  import pipeInto from 'https://cdn.skypack.dev/pipe-into';
</script>

README

Pipe Into

Simple implementation of the pipe pattern for Typescript.

Installation

npm i pipe-into

Usage

import { pipe } from "pipe-into";

const five = pipe(30)
    .into(v => v * 3)
    .into(v => v / 9)
    .into(v => v / 2)
    .val;

Building and Testing

npm test # If no error is thrown, the tests succeeded.