Hacker News new | ask | show | jobs
by pseudopuppet 1301 days ago
Inspired by trpc and KoaJS, I started to think if the RESTful world can have something with native type support. Spent several days and here's the result:

- No mind-switch, still RESTful

- Write typed APIs, get a typed client free

- Guard request input (path params, query, body) and output (response)

- Minimalism, zero dependency and framework-agnostic (Use any parser or fetch polyfill if needed)

- Auto OpenAPI JSON generation

Some thoughts about future:

- Make it for prod use

- Infer CRUD APIs from a single type definition

The POC fits my needs, but don't know if it's a good idea to proceed. Is there any existing project like this? Please let me know.