loopbackio / loopbackio/loopback4-extension-grpc
Auto generate typescript interfaces/classes from proto.file
@jonathan-casarrubias is already working on this.
Since Nov 24, 2017.
- Dominant language
- TypeScript
- Stars
- 18
- Forks
- 8
- PR merge metrics
- No merged PRs in 30d
Description
> ### Original Description
> To eliminate two files definition by users (proto.file and typescript) we can create a tool to automatically generate typescript interfaces/classes from a proto file and add it, for example, to CLI.
>
> Interesting example is this tool -> https://geotho.github.io/protobuf-to-typescript/
> But the main problem this tool doesn't handle services and RPC methods.
>
> Maybe we need to create our generating tool based on this? If yes, where to put our tool and how it will work?
>
Implement auto-generated typescript interfaces and classes from proto files. This should automatically discover and watch proto files.
PR: https://github.com/strongloop/loopback4-extension-grpc/pull/17 https://github.com/strongloop/loopback4-extension-grpc/pull/18 https://github.com/strongloop/loopback4-extension-grpc/pull/22
1. [X] Autodiscover protofiles within project directory
2. [X] Generate declaration and service file from proto file
3. [X] Improve decorator to receive TS gencode
4. [X] Improve gRPC Server to accept TS gencode
5. [X] Fix generator output structure
6. [ ] Watch for proto files changes to generate updated TS Files
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.