0

InfernoJS gives a very interesting but unfortunately very brief sketch of a purely functional way to bootstrap an app:

import Inferno from 'inferno';
import { scan, map } from 'most';

...
const model$ = scan(update, 0, actions$);
const vNodes$ = map(view(actions$), model$);
const renderer = Inferno.createRenderer();
const runApp = () => scan(renderer, container, vNodes$).drain();

runApp();

Can anyone give a fully functional example of an app designed this way?

Dmitri Zaitsev
  • 13,548
  • 11
  • 76
  • 110

1 Answers1

0

Here is an example: https://github.com/joshburgess/inferno-most-fp-demo

It's simply a functional counter but a good starting point nonetheless.

Adam Recvlohe
  • 334
  • 1
  • 11