News for hackers. Stuff that matters.
Re:Protobuf-ES: The Protocol Buffers TypeScript/JavaScript r... by throwthere on Monday October 31, 2022 @09:51AM (#33405682)
tRPC is another similar library.

https://trpc.io/docs/v10/quickstart

Re:Protobuf-ES: The Protocol Buffers TypeScript/JavaScript r... by jasperpressplay on Monday October 31, 2022 @10:22AM (#33406103)
There’re some key differences though, one being you can use plain typescript types to define your models, instead of a validation lib like zod :)
Re:Protobuf-ES: The Protocol Buffers TypeScript/JavaScript r... by simlevesque on Monday October 31, 2022 @10:44AM (#33406463)
Zod gives you a lot more of control on the schema.
Re:Protobuf-ES: The Protocol Buffers TypeScript/JavaScript r... by jasperpressplay on Monday October 31, 2022 @11:49AM (#33407515)
That’s an interesting point, can you give an example of that?
Re:Protobuf-ES: The Protocol Buffers TypeScript/JavaScript r... by simlevesque on Monday October 31, 2022 @01:22PM (#33409204)
You can use any custom validation there is for any field.