improbable-eng / ts-protoc-gen

Protocol Buffers Compiler (protoc) plugin for TypeScript and gRPC-Web.
Apache License 2.0
1.36k stars 173 forks source link

d.ts files not generated #282

Open onthegit opened 3 years ago

onthegit commented 3 years ago

Hello,

when I run the following command protoc --plugin=protoc-gen-ts=/usr/local/bin/protoc-gen-ts --js_out=import_style=commonjs,binary:. --ts_out=service=grpc-web:. -I=. blog.proto

only two files are generated: blog_pb.js blog.ts

there are no d.ts files generated. protoc is v3.14.0 protoc-gen-ts is 0.3.9

onthegit commented 3 years ago

Os: Linux Fedora

Blog.proto:

syntax = "proto3";

 message GetPostIn {
        string Path =1;
    }

    message GetPostRet {
        bool Success=1;
        string Msg=2;  
        string Post=3;
    }

    service BlogService {
        rpc GetPost(GetPostIn) returns(GetPostRet);
    }
jluttrell commented 2 years ago

I'm getting this same issue.. the ProtoName_grpc_pb.js and ProtoName_pb.js files are getting generated but then only a single ProtoName.ts file

jluttrell commented 2 years ago

wow nvm... it was because I was using protoc-gen-ts and not ts-protoc-gen. 🤦‍♂️

zzzz465 commented 2 years ago

I was experiencing the same issue. thanks