booger
v1.0.9
Published
RPC
Downloads
12
Readme
A library for creating online APIs using TypeScript. The server-side is described as classes, and the client-side is generated at runtime.
What is it
Booger is a library for creating online RPC services. It uses ws as the transport. The main idea is to write minimal code only for the server-side, and use definitions for autocompletion and build-time checking on the client-side. The secondary goal is to utilize the capabilities of online connections to enhance RPC functionality.
This is an experiment to test ideas. Currently, everything is being tested in controlled environments, with modern browsers and Node.js used as the client-side.
Features...
These are the convenience features implemented in the library:
- Validation of incoming and outgoing data using Zod schemas;
- Definitions for convenient type usage on the client-side;
- File uploads;
- Cookie handling;
Online Connection Capabilities
Thanks to the online connection, several interesting features have been implemented. It's still unclear what their purpose is, but they look intriguing.
- Instances;
- Server can send events to clients;
- Special fields;
Special Features
Hooks allow intercepting control at important points;
For each client-side action, you can create a factory and create an object of its type;
Can certain entities be created automatically upon connection?