Skip to content

fable-meiosis/fable-flyd

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Fable flyd stream bindings

Fable bindings for Flyd, a minimalistic but powerful, modular, functional reactive programming library.

Why?

Flyd can be used with the excellent Meiosis pattern as a building block for next gen elmish like architecture.

Status

WIP: Not yet tested

Overview

This example aims to showcase how to create custom Fable bindings for a JS library.

The initial bindings in Flyd.fs were created via ts2fable using the Flyd index.d.ts TypeScript definitoons file.

Checkout other sample apps at fable2-samples

Requirements

Building and running the app

install JS dependencies

  • yarn install

install F# dependencies

  • Windows: .paket/paket.exe install
  • Non-Windows: mono .paket/paket.exe install

Alternatively install paket as a global .NET tool

$ dotnet tool install --tool-path ".paket" Paket --add-source https://api.nuget.org/v3/index.json --framework netcoreapp2.1

With defaults, try simply: $ dotnet tool install Paket

In this case, make sure that the install location of paket is in your system PATH, see: dotnet-tool-install

Start and run

  • npm start to compile and watch with fable-splitter.

Alternatively:

  • npm run build - same but outputs javascript to /out.

Add F# Modules

While fable-splitter is watching with one of above npm commands:

  • Add nuget ModuleName to paket.dependencies and run paket install command above.
  • Add ModuleName to src/paket.references

Source Files

  • App.fsporj - add source paths here. Note paket.references is referenced here.
  • App.fs - starting point.
  • Util/File.fs - sample lib file.

About

Fable bindings for Flyd (reactive stream) library

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages