Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

grpc_tools_node_protoc_ts

Package Overview
Dependencies
Maintainers
1
Versions
67
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

grpc_tools_node_protoc_ts - npm Package Compare versions

Comparing version 5.0.1 to 5.1.0

1

build/lib/Debug.js
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.Debug = void 0;
const LibUtil = require("util");

@@ -4,0 +5,0 @@ const LibFs = require("fs");

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.DependencyFilter = void 0;
exports.DependencyFilter = [

@@ -4,0 +5,0 @@ "google/api/annotations.proto",

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.ExportMap = void 0;
class ExportMap {

@@ -4,0 +5,0 @@ constructor() {

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.EnumFormatter = void 0;
var EnumFormatter;

@@ -4,0 +5,0 @@ (function (EnumFormatter) {

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.ExtensionFormatter = void 0;
const Utility_1 = require("../../Utility");

@@ -4,0 +5,0 @@ const FieldTypesFormatter_1 = require("./FieldTypesFormatter");

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.FieldTypesFormatter = exports.JS_NUMBER = exports.JS_STRING = exports.JS_NORMAL = exports.ENUM_TYPE = exports.BYTES_TYPE = exports.MESSAGE_TYPE = void 0;
const Utility_1 = require("../../Utility");

@@ -4,0 +5,0 @@ exports.MESSAGE_TYPE = 11;

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.MessageFormatter = exports.OBJECT_TYPE_NAME = void 0;
const descriptor_pb_1 = require("google-protobuf/google/protobuf/descriptor_pb");

@@ -4,0 +5,0 @@ const Utility_1 = require("../../Utility");

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.OneofFormatter = void 0;
const Utility_1 = require("../../Utility");

@@ -4,0 +5,0 @@ var OneofFormatter;

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.ProtoMsgTsdFormatter = void 0;
const Utility_1 = require("../Utility");

@@ -4,0 +5,0 @@ const WellKnown_1 = require("../WellKnown");

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.ProtoSvcTsdFormatter = void 0;
const Utility_1 = require("../Utility");

@@ -4,0 +5,0 @@ const TplEngine_1 = require("../TplEngine");

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.TplEngine = void 0;
const LibFs = require("fs");

@@ -4,0 +5,0 @@ const LibPath = require("path");

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.Utility = void 0;
const PROTO2_SYNTAX = "proto2";

@@ -4,0 +5,0 @@ var Utility;

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.WellKnownTypesMap = void 0;
exports.WellKnownTypesMap = {

@@ -4,0 +5,0 @@ "google/protobuf/compiler/plugin.proto": "google-protobuf/google/protobuf/compiler/plugin_pb",

10

package.json
{
"name": "grpc_tools_node_protoc_ts",
"version": "5.0.1",
"version": "5.1.0",
"description": "Generate d.ts definitions for generated js files from grpc_tools_node_protoc",
"main": "build/index.js",
"scripts": {
"build": "tsc -p . && cp -r src/lib/template build/lib",
"build": "./node_modules/.bin/tsc -p . && cp -r src/lib/template build/lib",
"test": "echo \"Error: no test specified\" && exit 1"

@@ -32,3 +32,3 @@ },

"google-protobuf": "3.12.4",
"handlebars": "4.7.4",
"handlebars": "4.7.6",
"handlebars-helpers": "0.10.0"

@@ -38,6 +38,6 @@ },

"@types/google-protobuf": "3.7.2",
"@types/node": "12.12.6",
"@types/node": "14.14.16",
"tslint": "5.9.1",
"typescript": "2.7.2"
"typescript": "4.1.3"
}
}

@@ -31,2 +31,7 @@ grpc_tools_node_protoc_ts

## Breaking changes
### v5.1.0
Fix server implementation signature issue of `grpc_js` side. See: [Issue#79](https://github.com/agreatfool/grpc_tools_node_protoc_ts/issues/79).
About the code changes, please read the doc at **Changes** part.
### v4.0.0

@@ -384,3 +389,3 @@ Fix the issues along with [grpc-tools@1.9.0](https://github.com/grpc/grpc-node/releases/tag/grpc-tools%401.9.0), see: [PR#55](https://github.com/agreatfool/grpc_tools_node_protoc_ts/pull/55). If you are using grpc-tools with version under `1.9.0`, you should `NOT` upgrade.

interface IBookServiceService_IGetBook extends grpc.MethodDefinition<book_pb.GetBookRequest, book_pb.Book> {
path: string; // "/com.book.BookService/GetBook"
path: "/com.book.BookService/GetBook";
requestStream: false;

@@ -394,3 +399,3 @@ responseStream: false;

interface IBookServiceService_IGetBooksViaAuthor extends grpc.MethodDefinition<book_pb.GetBookViaAuthor, book_pb.Book> {
path: string; // "/com.book.BookService/GetBooksViaAuthor"
path: "/com.book.BookService/GetBooksViaAuthor";
requestStream: false;

@@ -404,3 +409,3 @@ responseStream: true;

interface IBookServiceService_IGetGreatestBook extends grpc.MethodDefinition<book_pb.GetBookRequest, book_pb.Book> {
path: string; // "/com.book.BookService/GetGreatestBook"
path: "/com.book.BookService/GetGreatestBook";
requestStream: true;

@@ -414,3 +419,3 @@ responseStream: false;

interface IBookServiceService_IGetBooks extends grpc.MethodDefinition<book_pb.GetBookRequest, book_pb.Book> {
path: string; // "/com.book.BookService/GetBooks"
path: "/com.book.BookService/GetBooks";
requestStream: true;

@@ -465,2 +470,35 @@ responseStream: true;

## Changes
### 5.1.0
Fix server implementation signature issue of `grpc_js` side. See: [Issue#79](https://github.com/agreatfool/grpc_tools_node_protoc_ts/issues/79).
Breaking change, only `grpc_js` side would be affected.
The interface of service server now extends `grpc.UntypedServiceImplementation` (examples/src/grpcjs/proto/book_grpc_pb.d.ts).
```typescript
// from
export interface IBookServiceServer {}
// to
export interface IBookServiceServer extends grpc.UntypedServiceImplementation {}
```
And the server implementation have to add a line of codes:
```typescript
class ServerImpl implements IBookServiceServer {
[name: string]: grpc.UntypedHandleCall;
// others ...
}
```
If this line of code not added, there will be some error:
```
TS2420: Class 'ServerImpl' incorrectly implements interface 'IBookServiceServer'.
Index signature is missing in type 'ServerImpl'.
```
Have a look at: [Typescript: Index signature is missing in type](https://stackoverflow.com/questions/37006008/typescript-index-signature-is-missing-in-type).
### 5.0.1

@@ -467,0 +505,0 @@ Fix array.includes issue. See: [Issue#73](https://github.com/agreatfool/grpc_tools_node_protoc_ts/issues/73), [Commit#1e4ae67](https://github.com/agreatfool/grpc_tools_node_protoc_ts/commit/1e4ae677d2f1f0066a21fe5e9dd48b10dd24f5af).

{
"compilerOptions": {
"target": "ES6",
"target": "ES2017",
"module": "commonjs",

@@ -5,0 +5,0 @@ "sourceMap": true,

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc