# protoc-gen-grpc-ts

> Protocol Buffers Compiler (protoc) plugin for generating grpc interfaces in TypeScript..

Latest version **1.0.1** (published 2018-06-06) · MIT license · 0 weekly downloads

> **Deprecated.** This package is deprecated.

## Install

```sh
npm install protoc-gen-grpc-ts
pnpm add protoc-gen-grpc-ts
yarn add protoc-gen-grpc-ts
bun add protoc-gen-grpc-ts
```

Provides the commands `protoc-gen`, `protoc-gen-grpc`, `protoc-gen-grpc-ts`, `protoc-gen-ts-plugin`.

## Health

**Score 10/100 (F)** — status: deprecated.

Negative: deprecated.

## Facts

| | |
|---|---|
| Version | 1.0.1 |
| Published | 2018-06-06 |
| First published | 2018-04-11 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Node | >=8 |
| Dependencies | 2 |
| Unpacked size | 1.9 MB |
| Known vulnerabilities | 0 |
| Install scripts | yes |
| Author | fengjie |
| Maintainers | niklaus0823 |
| Keywords | TypeScript, Protobuf, gRPC |

## Links

- npm: https://www.npmjs.com/package/protoc-gen-grpc-ts
- Repository: https://github.com/niklaus0823/protoc-gen-grpc-ts
- Homepage: https://github.com/niklaus0823/protoc-gen-grpc-ts#readme
- Issues: https://github.com/niklaus0823/protoc-gen-grpc-ts/issues
- npm.io page: https://npm.io/package/protoc-gen-grpc-ts

## Dependencies (2)

- [node-pre-gyp](https://npm.io/package/node-pre-gyp.md) ^0.10.0
- [google-protobuf](https://npm.io/package/google-protobuf.md) ^3.5.0

## Alternatives

- [@openai/codex-sdk](https://npm.io/package/@openai/codex-sdk.md) — 731.4K weekly downloads
- [babel-plugin-transform-react-jsx](https://npm.io/package/babel-plugin-transform-react-jsx.md) — 565.0K weekly downloads
- [babel-helper-remove-or-void](https://npm.io/package/babel-helper-remove-or-void.md) — 508.5K weekly downloads
- [@pnpm/store-controller-types](https://npm.io/package/@pnpm/store-controller-types.md) — 186.9K weekly downloads
- [react-native-signature-canvas](https://npm.io/package/react-native-signature-canvas.md) — 155.6K weekly downloads

## Recent versions

- 1.0.1 (latest) — 2018-06-06
- 1.0.0 — 2018-04-11

## README

protoc-gen-grpc-ts
=========================
Protocol Buffers Compiler (protoc) plugin for generating grpc interfaces in TypeScript.

## Aim

This project was forked from [agreatfool/grpc_tools_node_protoc_ts](https://github.com/agreatfool/grpc_tools_node_protoc_ts), and was intended to fix an error in Window10: `%1 XXX not a valid win32 application`

* difference
  * No other tools (or npm global package) need to be installed. such as `protoc`, `grpc_tools`
  * Remove handlebar template engine. 
  * Support: Linux, OSX, Windows

## Install

```bash
npm config set unsafe-perm true
npm install protoc-gen-grpc-ts -g
```
> If you don't want to set up a public configuration for NPM, you can try to add after the installation command `-unsafe-perm` parameters.

## How to use

```bash
# generate js codes
protoc-gen-grpc \
--js_out=import_style=commonjs,binary:./examples/src \
--grpc_out=./examples/src \
--proto_path ./examples/proto \
./examples/proto/book.proto

# generate d.ts codes
protoc-gen-grpc-ts \
--ts_out=service=true:./examples/src \
--proto_path ./examples/proto \
./examples/proto/book.proto
```
## Tool Chain

- [protoc-gen-grpc-ts](https://github.com/niklaus0823/protoc-gen-grpc-ts)
- [matrixes-cli](https://github.com/niklaus0823/matrixes-cli)
- [matrixes-lib](https://github.com/niklaus0823/matrixes-lib)

## Simple

- [matrixes-simple](https://github.com/niklaus0823/matrixes-simple)

---
_Source: https://npm.io/package/protoc-gen-grpc-ts · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
