grpc-web icon indicating copy to clipboard operation
grpc-web copied to clipboard

Please, update all examples!

Open Fl0pZz opened this issue 4 years ago • 1 comments

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.

Fl0pZz avatar Mar 06 '20 11:03 Fl0pZz

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

TomasMoskala avatar May 31 '20 14:05 TomasMoskala