Questions tagged [typegraphql]

TypeGraphQL is an amazing toolkit that offers a plethora of decorators enabling users to effortlessly define various components of their schema.

Using TypeORM with a MySQL database to assign empty values to optional parameters

Currently, I am in the process of developing a GraphQL mutation for updating user account details within my application. These account details include fields for gender and birthday, both of which are optional. Here is an example of my InputType: @InputTyp ...

Version 13.5 of NextJS is triggering errors in the GraphQL schema

Ever since I updated to NextJS 13.5, I've been encountering these errors specifically when deploying on Vercel (although everything works fine locally): Error: Schema must contain uniquely named types but contains multiple types named "h". at new GraphQL ...

Merging Type-GraphQL and Typegoose through a Variety of Decorators

Using a combination of Type-GraphQl and Typegoose, I aim to streamline my data definitions by consolidating them into one source for both GraphQL schemas and Mongoose queries. Is it feasible to merge the two libraries in a way that allows me to describe bo ...

Optimal approach to managing one-to-many relationships using type-graphql, typeorm, and dataloader

Currently, I am exploring the most effective method to manage a one-to-many relationship in a postgresql database using type-graphql and typeorm in conjunction with apollo server and express. I have a user table that is linked to a courses table through a ...

What is the solution for resolving array items in a GraphQL query?

I am facing an issue with my graphql Query, specifically in trying to retrieve all the fields of a Post. { getSpaceByName(spaceName: "Anime") { spaceId spaceName spaceAvatarUrl spaceDescription followin ...

The TypeScript reflection system is unable to deduce the GraphQL type in this case. To resolve this issue, it is necessary to explicitly specify the type for the 'id' property of the 'Address'

import { ObjectType, ID, Int, Field } from 'type-graphql'; @ObjectType() export default class Address { @Field(type => ID) id: String; @Field() type: string; @Field() title: string; @Field() location: string; } More information: ts-n ...

typegrapql encounters an issue with experimentalDecorators

I'm currently delving into TypeGraphQL and working on building a basic resolver. My code snippet is as follows: @Resolver() class HelloReslover { @Query(() => String) async hello(){ return "hello wtold" } } However, ...