为装饰器提供原生支持,并实现一种与 NestJS 约定一致的观点驱动方法。
NestJS tRPC is a library designed to integrate the capabilities of tRPC into the NestJS framework. It aims to provide native support for decorators and implement an opinionated approach that aligns with NestJS conventions.
express, fastify, and zod with more drivers to comeTo install NestJS tRPC with your preferred package manager, you can use any of the following commands:
# bun
bun add nestjs-trpc zod @trpc/server
# npm
npm install nestjs-trpc zod @trpc/server
# pnpm
pnpm add nestjs-trpc zod @trpc/server
# yarn
yarn add nestjs-trpc zod @trpc/serverRun the CLI to generate your AppRouter types:
# Generate types (one-time)
npx nestjs-trpc generate
# Watch mode for development
npx nestjs-trpc watchHere's a brief example demonstrating how to use the decorators available in NestJS tRPC:
…** See full documentation on NestJS-tRPC.io. **
NestJS tRPC is developed by Kevin Edry, which taken a huge inspiration from both NestJS and tRPC inner workings.
暂无开放 Issues,或尚未同步最近议题。