我将@nest/graphql的版本从7.9.11更新到7.11.0,现在我有了以下错误:
src/app.module.ts:26:7 - error TS2345: Argument of type '{ path: string; autoSchemaFile: string; sortSchema: true; playground: boolean; }' is not assignable to parameter of type 'GqlModuleOptions'.
Object literal may only specify known
我开始用Nest构建我的第一个API。我正在尝试添加GraphQL,并且在非常简单的情况下得到了一个问题。
TypeError: graphql_1.parse is not a function
at Object.<anonymous> (C:\Users\marek\dev\eparafie\api-nest\node_modules\apollo-server-core\node_modules\graphql-tools\src\stitching\introspectSchema.ts:7:48)
at Module._compile (internal
我对使用prisma + graphQL + nestjs有异议。它不断地告诉我,它无法确定graphQL输入类型:"Error:无法确定“父”的GraphQL输入类型("Org")。请确保您的类使用了适当的装饰符。“
这是我的prisma模式
model Org {
id String @id @default(uuid())
name String
parentId String? //an org can have a single parent org
parent Org? @relation("Pare
(node:8356) UnhandledPromiseRejectionWarning: Error: No type definitions were found with the specified file name patterns: "./**/*.graphql". Please make sure there is at least one file that matches the given patterns.
at GraphQLTypesLoader.<anonymous> (E:\NestJS\Template_Login\tea
我在寻找一件事。实际上,我正在用nestjs构建一个nestjs。在这里,我希望ID输入@Args输入。
举个例子-
import { Resolver, Mutation, Query, Args, Context, ID } from "@nestjs/graphql";
@Mutation(() => SuccessInfo, { name: "addSubCategory" })
addSub(
@Args("id") id: ID // Here is type ID
) {
console.l
我正在使用NestJS、TypeORM和GraphQL作为我的后端应用程序接口。我得到以下错误: GraphQLError [Object]: Query root type must be provided.
at SchemaValidationContext.reportError (/home/wise-introvert/Container/Projects/the-notebook/app/server/node_modules/graphql/type/validate.js:88:19)
at validateRootTypes (/home/wise
我的NestJs应用程序出现了问题。直到昨天,项目一直运行得很完美。
显然,我的node.js从14.16.1升级到了14.17.0。所以我在package.json中的engines对象中更改了这个版本号。我再次执行yarn install,以确保所有内容都在那里,并尝试了yarn start:dev (翻译为nest start --watch)。
但我的应用程序没有运行=(我的apollo-server-fastify似乎有问题:
UnhandledPromiseRejectionWarning: Error: You must `await server.start()` before