unlight / prisma-nestjs-graphql

Generate object types, inputs, args, etc. from prisma schema file for usage with @nestjs/graphql module
MIT License
539 stars 79 forks source link

The generated BigInt type is incorrect #223

Open imoyh opened 1 week ago

imoyh commented 1 week ago

prisma version: 5.21.1 prisma-nestjs-graphql version: 20.0.3

The Prisma Schema defines a BigInt type, but the generated model and input classes have Field types that are String.

This is the Prisma Schema definition:

image

After generation:

image

unlight commented 4 days ago

GraphQL does not natively support a BigInt type, as its standard Int type is limited to 32-bit integers.

See example in documentation https://github.com/unlight/prisma-nestjs-graphql?tab=readme-ov-file#graphqlscalars