-
Notifications
You must be signed in to change notification settings - Fork 87
Open
Labels
bugSomething isn't workingSomething isn't workingtriagedIssue has been triagedIssue has been triaged
Description
here is the proto file
syntax="proto3";
package test;
option go_package="test/api;api";
import "pbex/pbex.proto";
service test{
rpc hello_world(hello_world_req)returns(hello_world_resp){
option (pbex.method)="get";
}
}
message hello_world_req{
string str=1[(pbex.string_bytes_len_eq)=10];
}
message hello_world_resp{
string str=1;
}
here is the command to generate code
protoc -I ./ -I /path/to/pbex.proto --js_out=import_style=commonjs,binary:. *.proto
here is the generated code
var jspb = require('google-protobuf');
var goog = jspb;
var global = globalThis;
var pbex_pbex_pb = require('../pbex/pbex_pb.js');
goog.object.extend(proto, pbex_pbex_pb);
goog.exportSymbol('proto.test.hello_world_req', null, global);
goog.exportSymbol('proto.test.hello_world_resp', null, global);
......
the code will require pbex_pb.js,this should not be generated.
if i use golang's protoc-gen-go to generate the golang's code,it will ignore the extend,only generate the message struct
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't workingtriagedIssue has been triagedIssue has been triaged