protobuf-es
tygo
protobuf-es | tygo | |
---|---|---|
7 | 8 | |
937 | 530 | |
2.8% | - | |
9.2 | 7.3 | |
2 days ago | 2 months ago | |
TypeScript | Go | |
Apache License 2.0 | MIT License |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
protobuf-es
-
gut: convert golang structs to typescript interfaces
Yes, you can. You are mistaking protobuf with gRPC. See this for more information.
-
TypeScript type safety with GO
You can use this with connect: https://github.com/bufbuild/protobuf-es
-
Ask HN: Why isn't JSON-RPC more widely adopted?
Ah you should check out https://github.com/bufbuild/protobuf-es which feels great so far. Then there's connect by the same buf people but it has a grpc-web option https://connect.build/docs/web/getting-started/. The amount of code generated is also tiny, which I love.
-
Connect-Web: ergonomic Protobuf & gRPC for browsers
I'd recommend looking into protobuf-ts (Timo from Buf) or protobuf-es (Buf maintained).
-
Connect-Web: It's time for Protobuf/gRPC to be your first choice in the browser
Not sure if it is a magic bullet, but it was definitely written by TypeScript developers, for TypeScript developers.
The generated TypeScript code is already pretty minimal because all serialization ops are implemented with reflection instead of generated code (which is only marginally slower than generated code in JS).
But you can also switch to generating JavaScript + TypeScript declaration files, which is truly minimal: JavaScript is an entire dynamic language, so we actually only generated a small snippet of metadata in the .js output, and create a class at run time with a function call. The generated typings (.d.ts) give you type safety, autocompletion in the IDE, and so on.
You can see the output here: https://github.com/bufbuild/protobuf-es/blob/main/packages/p...
- Connect: A Better gRPC
tygo
-
gut: convert golang structs to typescript interfaces
Cool! I remember using tygo. How's this different? https://github.com/gzuidhof/tygo
-
Generate types for TS
I use https://github.com/gzuidhof/tygo for generating my TS types directly from go structs.
- Tygo [Go -> Typescript typings transpiler] Now supports 1.18 generics
- Tygo - Generate Typescript types from Golang source code
- gzuidhof/tygo : Generate Typescript types from Golang source code
- Show HN: Tygo – Generating TypeScript typings from Go code
-
Introducing Tygo: A tool for generating Typescript typings from your Go code
https://github.com/gzuidhof/tygo
What are some alternatives?
ts-proto - An idiomatic protobuf generator for TypeScript
typescriptify-golang-structs - A Golang struct to TypeScript class/interface converter
connect-go - Moved to https://github.com/connectrpc/connect-go
htmx - </> htmx - high power tools for HTML
bloomrpc - Former GUI client for gRPC services. No longer maintained.
goa - 🌟 Goa: Elevate Go API development! 🚀 Streamlined design, automatic code generation, and seamless HTTP/gRPC support. ✨
protobuf-ts - Protobuf and RPC for TypeScript
buf - The best way of working with Protocol Buffers.
grpcurl - Like cURL, but for gRPC: Command-line tool for interacting with gRPC servers
Wails - Create beautiful applications using Go
connect-es - The TypeScript implementation of Connect: Protobuf RPC that works.
oto - Go driven rpc code generation tool for right now.