All Projects → Shmew → Feliz.Recoil

Shmew / Feliz.Recoil

Licence: MIT license
Fable bindings in Feliz style for Facebook's experimental state management library recoil.

Programming Languages

F#
602 projects
javascript
184084 projects - #8 most used programming language

Projects that are alternatives of or similar to Feliz.Recoil

Feliz.MaterialUI
Feliz-style Fable bindings for Material-UI
Stars: ✭ 57 (+32.56%)
Mutual labels:  fable, feliz
Feliz.MaterialUI.MaterialTable
Fable bindings written in the Feliz-style for material-table.
Stars: ✭ 17 (-60.47%)
Mutual labels:  fable, feliz
Feliz.Bulma
Bulma UI (https://bulma.io) wrapper for amazing Feliz DSL
Stars: ✭ 57 (+32.56%)
Mutual labels:  fable, feliz
atomic-state
A decentralized state management library for React
Stars: ✭ 54 (+25.58%)
Mutual labels:  state-management, recoil
SAFE.Simplified
A lightweight alternative template of SAFE for happy cross-IDE full-stack F# development
Stars: ✭ 97 (+125.58%)
Mutual labels:  fable, feliz
navigation-bar-with-feliz
Modern navigation bar built with Feliz
Stars: ✭ 20 (-53.49%)
Mutual labels:  fable, feliz
Feliz.ViewEngine
Feliz DSL and engine for HTML generation and server side rendering (SSR)
Stars: ✭ 53 (+23.26%)
Mutual labels:  fable, feliz
particule
Fine-grained atomic React state management library
Stars: ✭ 31 (-27.91%)
Mutual labels:  state-management, recoil
getx snippets extension
An extension to accelerate the process of developing applications with flutter, aimed at everyone using the GetX package.
Stars: ✭ 142 (+230.23%)
Mutual labels:  state-management
angular-workshop
Learning Angular: From component state to NgRx
Stars: ✭ 40 (-6.98%)
Mutual labels:  state-management
rescript-pulo
⚡️ [Pulo.dev] with ReScript, React, Recoil, and Chakra
Stars: ✭ 12 (-72.09%)
Mutual labels:  recoil
whatsup
Reactive framework, simple, fast, easy to use!
Stars: ✭ 115 (+167.44%)
Mutual labels:  state-management
react-coat-ssr-demo
Demo with Typescript + React + Redux for server-side-rendering (SSR)
Stars: ✭ 100 (+132.56%)
Mutual labels:  state-management
ReduxSwift
Predictable state container for Swift too
Stars: ✭ 38 (-11.63%)
Mutual labels:  state-management
fs2-es
Event sourcing utilities for FS2
Stars: ✭ 75 (+74.42%)
Mutual labels:  state-management
statebot-sh
Statebot for shell-scripts. Write more robust and understandable programs.
Stars: ✭ 14 (-67.44%)
Mutual labels:  state-management
flutter expense manager
Flutter Provider and Shared Preferences Sample Application.
Stars: ✭ 59 (+37.21%)
Mutual labels:  state-management
reactive state
An easy to understand reactive state management solution for Flutter.
Stars: ✭ 19 (-55.81%)
Mutual labels:  state-management
Fable.Lit
Write Fable Elmish apps with Lit
Stars: ✭ 64 (+48.84%)
Mutual labels:  fable
wedi
[Deprecated] A lightweight dependency injection (DI) library for TypeScript, along with a binding for React.
Stars: ✭ 22 (-48.84%)
Mutual labels:  state-management

Feliz.Recoil Nuget

Fable bindings in Feliz style for Facebook's experimental state management library recoil.

A great intro to the library can be found here.

A quick look:

open Feliz
open Feliz.Recoil

let textState = Recoil.atom("textState", "Hello world!")

let vowels = [ 'a'; 'e'; 'i'; 'o'; 'u' ]

let textStateTransform =
    Recoil.selector(fun getter ->
        getter.get(textState)
        |> String.filter(fun v -> List.contains v vowels)
    )

let inner = React.functionComponent(fun () ->
    let setAtomText = Recoil.useSetState(textState)
    let text = Recoil.useValue(textStateTransform)

    Html.div [
        Html.div [
            prop.text (sprintf "Transformed value: %s" text)
        ]
        Html.input [
            prop.type'.text
            prop.onTextChange setAtomText
        ]
    ])

let otherInner = React.functionComponent(fun () ->
    let textAtom = Recoil.useValue(textState)

    Html.div [
        prop.text (sprintf "Atom current value: %s" textAtom)
    ])

let render = React.functionComponent(fun () ->
    Recoil.root [
       inner()
       otherInner()
    ])

Full documentation with live examples can be found here.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].