Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

fleuvejs

Package Overview
Dependencies
Maintainers
1
Versions
25
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

fleuvejs

A simple JavaScript Observable Library

  • 1.0.8
  • Source
  • npm
  • Socket score

Version published
Maintainers
1
Created
Source

FleuveJS

A simple Observable Utility library

Installation

npm i fleuvejs

How To Use

Instantiate a Fleuve

const johnDoe$ = new Fleuve({firstname: 'john', lastname: 'doe'});
const counter$ = new Fleuve(0);

Provide new values

const fleuve$ = new Fleuve(0);
fleuve$.next(12, 13, 14, 15, 16);
fleuve$.next((x) => x + 1, (x) => x * 2);

// This one will throw an error
fleuve$.next(12, (x) => x + 1);

Pipe the Fleuve

const fleuve$ = new Fleuve(18729);
const sum$ = fleuve$.pipe(
    (x) => (x + '').split(''), 
    (numbers) => numbers.reduce((acc, curr) => acc + curr, 0)
);

Subscribe

const fleuve$ = new Fleuve(12;
fleuve$.subscribe((value) => console.log(value));

// This one will throw an error
fleuve$.subscribe(42);

Keywords

FAQs

Package last updated on 10 Jun 2021

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc