grpc-web
grpc-web copied to clipboard
Please, update all examples!
Here's import from .d.ts: https://github.com/improbable-eng/grpc-web/blob/master/client/grpc-web-react-example/ts/src/index.ts#L3
However, from .js file exported proto.examplecom.library.Book
:
https://github.com/improbable-eng/grpc-web/blob/master/client/grpc-web-react-example/ts/_proto/examplecom/library/book_service_pb.js#L14
which be able import as:
import bookSrv from "../_proto/examplecom/library/book_service_pb";
const Book = bookSrv.examplecom.library.Book;
How does it work?? Compilation should fall with an error.
Just spent hours trying to make it work on Win10. Solved this by adding the old tree /_proto/examplecom/library/book_service_pb" to Go repository C:%users%\Go\src\github.com\improbable-eng\grpc-web\example\go_proto\examplecom\library