4 ms·
Personally, I find gRPC-Web very attractive but the current state of TypeScript/JS code-gen is very confusing and lacking. I would love something like https://
by vyrotek 4y ago
Personally, I find gRPC-Web very attractive but the current state of TypeScript/JS code-gen is very confusing and lacking.
I would love something like https://orval.dev https://orval.dev for gRPC-web. Have I missed something or is it just early to expect it?
I tried a few libraries but couldn't get them to work or would generate unappealing results. I believe I'm hitting this issue with my local experiments. https://github.com/grpc/grpc-web/issues/535 https://github.com/grpc/grpc-web/issues/535
UPDATE: I was able to get something working with these from a ReactJS app!
Server: https://learn.microsoft.com/en-us/aspnet/core/grpc/grpcweb https://learn.microsoft.com/en-us/aspnet/core/grpc/grpcweb
Client TS Gen: https://github.com/timostamm/protobuf-ts https://github.com/timostamm/protobuf-ts
- erdaniels 4y agoAh you should check out https://github.com/bufbuild/protobuf-es 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/ https://connect.build/docs/web/getting-started/. The amount of code generated is also tiny, which I love.