nice-grpc is a Node.js gRPC library that provides a modern, promise-based API with full TypeScript support. Current stable version is 2.1.16, with a release cadence of approximately every 2-3 months. It supports async-iterable server streaming, abort signals for cancellation, and integrates seamlessly with @grpc/grpc-js. Compared to grpc-js, it offers a higher-level, more ergonomic interface with automatic promise wrapping, streaming with async iterables, and built-in TypeScript types. It is designed to be compatible with all standard gRPC features including unary, server streaming, client streaming, and bidirectional streaming.
npm install nice-grpcNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Creates a gRPC channel and client, makes a unary RPC call with await, then closes the channel.
Migrate to ESM by setting 'type': 'module' in package.json or use .mjs extension. Alternatively, stick with v1.x (CJS).
Run 'npm install @grpc/grpc-js' as a dependency.
Replace deadline with AbortSignal: import { AbortController } from 'abort-controller' (if needed) and pass { signal: controller.signal }.Use for-await-of to consume the stream iterable properly.
Remove callback argument; use await or .then().
npm install @grpc/grpc-js
import { createClient } from 'nice-grpc'Use import syntax or switch to v1.x