It usually goes like this. You have a fullstack project and everything in it is fine. Types run end to end (tRPC, or generated from OpenAPI), auth is there, the features work. Then you decide to add realtime: a notification about a new post in the feed, a chat between users, an interactive board. And a whole new layer of abstractions shows up, one where you reinvent everything the project already has, only differently. From then on you maintain two separate systems.
Point0 has four new realtime points (structural units, the same kind of thing as pages, layouts, queries and mutations): channel, space, client handler, server handler. Almost any realtime feature is built out of those four, the code stays short, and it reads the way it works. These points carry the same properties as every other point:
- server and client code live in one file, and the compiler cuts the client code out of the server build and the server code out of the client build;
- types run end to end, inferred from the framework's own generics, with no code generation.
Below I go through it on examples and explain the paradigm, so that you can build any realtime app on it.