1.1.5 • Published 12 months ago

vir-line v1.1.5

Weekly downloads
-
License
(MIT or CC0 1.0)
Repository
github
Last release
12 months ago

vir-line

An assembly line or pipeline that automatically aggregates each of its stages into a final state object type and supports scoped state listeners.

Demo

Usage

Here's a simple example that defines a stage, constructs and then starts a VirLine instance. See the TypeScript types for further options.

Each stage is intended to directly mutate the state object that it is given.

import {VirLine, VirLineStage} from 'vir-line';

const countStage: VirLineStage<{count: number}> = {
    executor({state}) {
        state.count++;
    },
    stageId: {
        name: 'counter',
    },
};

const virLine = new VirLine(
    [
        countStage,
    ],
    {
        count: 0,
    },
);

virLine.startUpdateLoop();
1.1.5

12 months ago

1.1.4

12 months ago

1.1.3

12 months ago

1.1.2

12 months ago

1.1.1

12 months ago

1.1.0

12 months ago

1.0.2

12 months ago

1.0.1

12 months ago

1.0.0

12 months ago

0.0.0

12 months ago