fleur icon indicating copy to clipboard operation
fleur copied to clipboard

A fully-typed, type inference and testing friendly Flux Framework

ogp

🌼 Fleur 🌼 travis

An Fully-typed Flux framework inspired by Fluxible.
Runs on Node / Web.

(No dependence to React. See this if you want to use with React.)

Social hashtag: #fleurjs

Feature

  • Comfortable to write code
    • Fully typed. Friendly to type inference.
  • Next.js supported with create-fleur-next-app
  • Completely Server-side rendering support
  • Support React Hooks in @fleur/react

Packages

  • @fleur/fleur - Basic flux-flow framework
  • @fleur/react - Fleur react connector
  • @fleur/testing - Fleur Test helpers
  • @fleur/create-next-app - Create Next.js app with Fleur
  • @fleur/next - Next.js integration helpers
  • @fleur/di - Library independent DI function
  • fleur-benchmarks - Benchmarks. (Fleur vs Fluxible vs react-redux)
  • ~~@fleur/route-store-dom - Fleur DOM router~~

Usage

Recommended structure

Fleur recommends Re-ducks like directory structure.
See file details on packages/fleur/README.md

app/
  domains/
    User/
      actions.ts
      operations.ts
      store.ts
      selector.ts
    Article/
      actions.ts
      operations.ts
      store.ts
      selector.ts
  # and any components structure you liked (Atomic, Smart / dumb, etc...)
  components/
  containers/