connect-es
protobuf-es
Our great sponsors
connect-es | protobuf-es | |
---|---|---|
13 | 7 | |
1,202 | 932 | |
3.4% | 5.2% | |
9.2 | 9.2 | |
6 days ago | 2 days ago | |
TypeScript | TypeScript | |
Apache License 2.0 | Apache License 2.0 |
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.
connect-es
-
I Reviewed 1,000s of Opinions on gRPC
> However, it's important to note that browser support wasn't a primary focus in gRPC's design. This oversight necessitates an additional component, grpc-web, for browser accessibility. Furthermore, external services often have specific needs like caching and load balancing, which are not directly catered to by gRPC. Adopting gRPC for external services might require bespoke solutions to support these features.
The article should mention the Connect protocol for web-based Protobuf messaging:
https://connectrpc.com/
-
Creating the Local First Stack
We can solve this with a service! Now there are many ways I could have started, but I decided to test out gRPC along the way. This was a mistake. I hoped for the best, but gRPC ended up not being a good choice for the web client. Why? you ask. The gRPC protocol works with all the bells and whistles of http when used server to server, but web clients are not as great. The Javascript client is dependent on http 2.0, and it requires a proxy like Envoy to work with a browser. What's more, I didn't love the structure of the generated web client. So through the process of working on this 'local first stack' I actually got sucked in to a big rabbit hole in making the rpc system work. I ended up going with Connect which is a tool that can create a service from a protobuf service definition, that also talks a simple http 1.1 protocol. What ultimately sold me on this solution as the best is that it also came with a very nice to use web client generation, and even plugs in to my favorite react http helper useQuery.
-
Leveraging Temporal for resilient remote procedure calls (RPC)
Our stack at Escape is written in multiple languages because each team has specific needs. We use TypeScript for its vibrant ecosystem, Python for cybersecurity research and Go for performance-sensitive tasks. To orchestrate cross-language task orchestration, we first developed a simple request-response protocol over HTTP, but it wasn't sustainable as the Escape codebase grew rapidly. We evaluated several technologies to replace our homegrown protocol, and two emerged as the most promising options: Connect and Temporal. The title gives it away, but the reason is far from obvious
- Connect RPC – A Better gRPC
-
Building a modern gRPC-powered microservice using Node.js, Typescript, and Connect
protobuf messages we’ll configure (@bufbuild/connect-es)
-
TypeScript type safety with GO
try https://github.com/bufbuild/connect-web
-
Ask HN: Why isn't JSON-RPC more widely adopted?
As for better gRPC-web, you might want to look into connect-web https://github.com/bufbuild/connect-web
- When to use gRPC vs GraphQL
-
Protobuf-ES: The Protocol Buffers TypeScript/JavaScript runtime we all deserve
They already have! Connect (https://github.com/bufbuild/connect-web) is what you're looking for, as it's grpc-web compatible.
-
Connect-Web: It's time for Protobuf/gRPC to be your first choice in the browser
Ye, fwiw there is an example code size comparison here:
https://github.com/bufbuild/connect-web/blob/main/packages/c...
I'm sure someone will chime in on the implementation details, but hopefully others can give it a try with their projects!
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
What are some alternatives?
grpc-web - gRPC for Web Clients
ts-proto - An idiomatic protobuf generator for TypeScript
connect-go - Moved to https://github.com/connectrpc/connect-go
buf - The best way of working with Protocol Buffers.
bloomrpc - Former GUI client for gRPC services. No longer maintained.
fastify-autoroutes - fastest way to map directories to URLs in fastify
protobuf-ts - Protobuf and RPC for TypeScript
protoc-gen-validate - Protocol Buffer Validation - Being replaced by github.com/bufbuild/protovalidate
grpcurl - Like cURL, but for gRPC: Command-line tool for interacting with gRPC servers
fetch - Fetch Standard