Omran Jamal

RoastMyStartup: useSharedState - It's like useState but the state syncs across clients in real-time

by

I'm calling it AirState (https://airstate.dev). We're making a set of primitives and react hooks that help you build real-time applications in like 2 lines of change. Our first product is called SharedState, you can use it via the useSharedState hook in React.

It behaves exactly how to expect it to behave. It's a drop-in replacement for useState but it syncs across clients and computers in real-time. By default it connects to our cloud that has a free-tier but we'll also open source the server so that people can self-host it. Kinda following in the footsteps of PostHog.

SharedState™️ by AirState™️ uses CRDTs (YJS) under the hood so it is conflict-free by default and our server scales horizontally and never misses a message (i.e. the two browsers will never be out of sync if they're online) thanks to NATS.

We're also working on other companion products to be more complete. (do let me know if I can elaborate?)

The plan is to charge $20 per for 10,000 unique clients, with $2/GB transferred. Free tier: 256 unique clients and 2GB transfer every month.

What do you guys think? It's okay to be brutally honest if you guys want.

63 views

Add a comment

Replies

Be the first to comment