Registry / devops / quant-grpc-docs

quant-grpc-docs

JSON →
library1.3.9jsnpmunverified

grpc-docs is a React component library that renders interactive gRPC API documentation, similar to Swagger UI but for gRPC. Current stable version is 1.3.9. It supports both self-generated protoc JSON definitions and integration with GenDocu Cloud for CI/CD. Provides two main components: GRPCSelfGeneratedAPIReference for local protobuf descriptions and GRPCGenDocuAPIReference for cloud-hosted docs. Works with React 16+.

npm install quant-grpc-docs
INSTALL
IMPORT
SIG · QUANT-GRPC-DOCS
Q
quant-grpc-docs
devopsjavascriptv1.3.9
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

GRPCSelfGeneratedAPIReference
import { GRPCSelfGeneratedAPIReference } from 'grpc-docs'
import GRPCSelfGeneratedAPIReference from 'grpc-docs'
This is a named export, not a default export.
GRPCGenDocuAPIReference
import { GRPCGenDocuAPIReference } from 'grpc-docs'
const GRPCGenDocuAPIReference = require('grpc-docs').GRPCGenDocuAPIReference
CommonJS users should destructure require, but the package is primarily ESM.
default import
import * as GrpcDocs from 'grpc-docs'
import GrpcDocs from 'grpc-docs'
No default export exists; use namespace import to access all named exports.

Shows how to render a self-generated protoc JSON descriptor using the GRPCSelfGeneratedAPIReference component.

import React from 'react'; import { GRPCSelfGeneratedAPIReference } from 'grpc-docs'; function App() { return ( <div> <h1>My gRPC API Reference</h1> <GRPCSelfGeneratedAPIReference file='./path/to/description.json' /> </div> ); } export default App;
Debug
Known issues
gotchaVersion 1.2.0 introduced a breaking change: the component prop `file` was renamed from `url`. Older versions expecting `url` will break.
fix
Update to 1.2.0+ and replace `url` prop with `file`.
affects: <1.2.0
deprecatedThe `GRPCSelfGeneratedAPIReference` component is now recommended over the older `GRPCAPIReference` component, which may be removed in a future release.
fix
Use `GRPCSelfGeneratedAPIReference` instead.
affects: >=1.0.0
breakingReact 17 support was dropped in version 1.3.0 — only React 16 is supported as a peer dependency.
fix
Downgrade to 1.2.x or use React 16.
affects: >=1.3.0
gotchaThe `file` prop for `GRPCSelfGeneratedAPIReference` must point to a JSON file generated by protoc-gen-doc with the `json` option. YAML files are not supported.
fix
Ensure you generate using `protoc --doc_out=./ --doc_opt=json,description.json *.proto`.
affects: >=1.0.0
Errors
Common errors & fixes
Module not found: Error: Can't resolve 'grpc-docs'
Package not installed or import path incorrect.
fix
Run `npm install grpc-docs` and ensure you use a named import like `import { GRPCSelfGeneratedAPIReference } from 'grpc-docs'`.
TypeError: Cannot read property 'map' of undefined
Invalid or missing JSON descriptor passed to the component.
fix
Verify the JSON file exists and is valid. Use `protoc-gen-doc` with `json` format.
Upgrade
Version history
1.3.9latest on npm
Audit
Dependencies
reactoptionalPeer dependency – required at React 16.0.0 or higher.
Agent activity
7 hits · last 30 days
node
6
Bingbot
1
Resources
quant-grpc-docs — npm install quant-grpc-docs · libregistry