A gRPC client wrapper that enhances the standard grpc-js client with promise and observable support, response transformation capabilities, and built-in mods to eliminate default proto values, remove null/undefined properties, and convert int64 to number. Version 1.1.1 requires peer dependency grpc ^1.8.0. Key differentiator: allows declarative response manipulation and modern async patterns without manually wrapping callbacks. Suitable for Node.js applications using gRPC that want to avoid callback hell and sanitize responses.
npm install grpc-modNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Shows how to create a gRPC-mod client and use promises/observables for unary and stream calls, plus enhancing an existing gRPC client.
Run 'npm install grpc' alongside grpc-mod.
Consider migrating to @grpc/grpc-js and using native promise support or a different wrapper.
Install rxjs with 'npm install rxjs' if you need to compose observables.
Use GRPCModClient constructor for a clean wrapper, or apply mod only once.
Set desired options when instantiating or enhancing the client.
Install grpc: npm install grpc
Ensure the proto file path, package name, and service name are correct. Use mod(client) after creating a grpc.Client.
Verify the proto file's RPC type. Use .toPromise() on the observable if you need a promise, or subscribe.