@in-code/signal-effects
TypeScript icon, indicating that this package has built-in type declarations

1.1.0 • Public • Published

@in-code/signal-effects

npm version npm downloads

This library is a simple but robust implementation reactive signals and effects. Signals and effect have become popular in web application frameworks because they allow a change in a value (signal) in one part of the application to implicitly trigger updates (effects) in dependent parts of the application. Most beneficially, signals do not need to understand the effects that depend upon them.

const length = signal(5.0);
const height = signal(2.5);

effect(() => {
  console.log(`area = ${length.value * height.value}`);
});

Install

npm i @in-code/signal-effects

License

MIT © kevin-in-code

/@in-code/signal-effects/

    Package Sidebar

    Install

    npm i @in-code/signal-effects

    Weekly Downloads

    4

    Version

    1.1.0

    License

    MIT

    Unpacked Size

    8.78 kB

    Total Files

    5

    Last publish

    Collaborators

    • kevin-in-code