I have a simple proto file:
syntax = "proto3";
package SettingsSvc;
service Settings {
rpc FetchSettings(SettingsRequest) returns (SettingsResponse) {}
}
message SettingsRequest {
string language = 1;
}
message SettingsResponse {
string cvTooltip = 1;
string themeTooltip = 2;
string githubLocation = 3;
string gitlabLocation = 4;
string linkedinLocation = 5;
string name = 6;
int32 year = 7;
}
I am trying to generate the files for a react (TS template) web client. As
suggested by the official grpc-web page
<https://github.com/grpc/grpc-web#typescript-support> I am running the
protoc command as follows:
protoc -I=. settings.proto --js_out=import_style=commonjs,binary:.
--grpc-web_out=import_style=typescript,mode=grpcweb:.
However, the only file I get is "settings_pb.js", which is the one
generated by the "--js_out" instruction. The file that should be generated
by the "--grpc-web_out" instruction (SettingsClientPb.ts) is missing.
I tried using "import_style=commonjs" and "import_style=commonjs+dts" as
well, but no luck. The command returns no errors but it does not produce
the expected output files.
I installed protoc with brew and I am using version 1.3.1 of the grpc-web
code generator plugin <https://github.com/grpc/grpc-web/releases/tag/1.3.1>.
Can someone help?
Thanks.
Antonello
--
You received this message because you are subscribed to the Google Groups
"grpc.io" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/grpc-io/88256c8f-70a4-4f62-8e3e-1b1210741d40n%40googlegroups.com.