1.0.4 • Published 11 months ago

ts-protobuf-build v1.0.4

Weekly downloads
-
License
ISC
Repository
github
Last release
11 months ago

Typescript Protobuf Build Tool

This project implements an NPM CLI wrapper tool for ts-proto to recursively generate TypeScript code for Protobuf definitions using NPM run scripts.

Usage

$ ts-protobuf-build

Options:
      --version  Show version number                                   [boolean]
  -d, --dir      Source directory                            [string] [required]
  -o, --out      Output directory                            [string] [required]
  -e, --ext      Proto file extensions             [array] [default: [".proto"]]
      --ignore   Ignore files matching JS RegExp           [array] [default: []]
      --interop  Compile with 'esModuleInterop' flag  [boolean] [default: false]
      --plugin   Path to the 'protoc-gen-ts_proto' plugin executable
                     [string] [default: "node_modules/.bin/protoc-gen-ts_proto"]
  -h, --help     Show help                                             [boolean]

Requirements

Please make sure that the protoc binary is installed.

Features

  • Pure NodeJS wrapper script (works on all platforms supporting NodeJS and protoc)
  • Searches source directory recursively for proto files
  • Generates TypeScript code from Protobuf definitions

Use case

This script is intended to be used in NPM run scripts.

1.0.4

11 months ago

1.0.3

11 months ago