Hacker News

bosmarcel
Show HN: Fluent-state: a new fresh take on local React state github.com

Hi HN

I built *fluent-state*, a lightweight React hook that replaces useState, useReducer, useMemo, and useEffect.

It gives you:

- A fluent, proxy-based API: `state.user.name('Joe')` - Immutable updates without spread logic - Automatic dependency tracking - Built-in `compute` for reactive, memoized derived state (no useMemo needed) - Built-in `effect` for reactive side-effects with automatic dependency tracking (no useEffect needed) - Zero boilerplate, full control

Designed for local state, nested structures, and clean, declarative code.

Demo: https://stackblitz.com/edit/vitejs-vite-uh4kyzkf?file=src%2F... GitHub: https://github.com/marsbos/fluent-state NPM: https://www.npmjs.com/package/fluent-state

Try it out plz.


bosmarcelop14 days ago

Hi everyone!

Thanks for the interest in fluent-state.

Just a quick note: for easy installation and trying out the demo, check out these links:

NPM: https://www.npmjs.com/package/fluent-state

Demo: https://stackblitz.com/edit/vitejs-vite-uh4kyzkf?file=src%2F...

The GitHub repo is still available here for source and issues: https://github.com/marsbos/fluent-state

Happy coding!

pedrochao198514 days ago

[dead]

pedrochao198514 days ago

[dead]

hn-front (c) 2024 voximity
source