diff --git a/packages/nestjs-trpc/lib/generators/router.generator.ts b/packages/nestjs-trpc/lib/generators/router.generator.ts index 6482b2d..4beef22 100644 --- a/packages/nestjs-trpc/lib/generators/router.generator.ts +++ b/packages/nestjs-trpc/lib/generators/router.generator.ts @@ -52,7 +52,9 @@ export class RouterGenerator { const classDeclaration = sourceFile.getClass(routerName); if (!classDeclaration) { - throw new Error(`Could not find router ${routerName} class declaration.`); + throw new Error( + `Could not find router ${routerName} class declaration. Did you set compilerOptions.sourceMap to true in tsconfig.json?`, + ); } const methodDeclaration = classDeclaration.getMethod(procedure.name);