Skip to main content
Start with the default React/Vite app. Add a messages table, a bounded query and an insert mutation, and place them in the app tree.
bijection/messages.ts
bijection/app.ts
The functions are exposed at messages.send and messages.list. Connect and create typed references from the app tree:
src/client.ts
In React, watch the list and hold the mutation:
src/Chat.tsx
Render it inside <Bijection client={client}>. Open a second tab to see a new message arrive in the watch. For private channels, give the table a label, give the functions an under and an allow of your own roles, and grant those roles.