Releases: MichalLytek/typegraphql-prisma
0.8.2
v0.8.1
Changelog
-
v0.8.1
now works with Prisma 2 stable release~2.8.1
which fixes some DMMF typings issues found inv2.8.0
. -
It now contains a runtime check for correct Prisma 2 version installed. This should prevent from reporting errors due to having wrong and unsupported version installed.
-
The type signature of input and output type fields of enum types has changed.
In the first releases it waskeyof typeof XYZEnumType
in order to provide interoperability with Prisma types.
Then it was changed totypeof XYZEnumType[keyof typeof XYZEnumType]
to support renaming fields. However, in new TS releases such types are wrapped back toXYZEnumType
which breaks Prisma types interoperability.Now enum typed fields have string literal union type signature which consist of prisma enum values:
@TypeGraphQL.Field(_type => [CategoryDistinctFieldEnum], { nullable: true }) - distinct?: Array<typeof CategoryDistinctFieldEnum[keyof typeof CategoryDistinctFieldEnum]> | undefined; + distinct?: Array<"name" | "slug" | "number"> | undefined;
-
Generator options now accept a new
simpleResolvers
settings which emitssimpleResolvers: true
in@ObjectType
decorator options for tuning the performance. You can read more about that feature in Readme:
https://github.com/MichalLytek/typegraphql-prisma#simple-resolvers-performance -
The
OutputType
suffix has been removed from aggregate output type names. It now generates classes named e.g.CategoryAvgAggregate
instead ofCategoryAvgAggregateOutputType
. Please update your client code if you were relying on__typename
values.
0.8.0
Changelog
-
New release updates Prisma 2 deps to
2.9.0-dev.36
which fixes some DMMF typings issues found in stablev2.8.0
.
It supports the case insensitive filters and also the newfindFirst
API and generate the proper query resolver for that. -
Thanks to the new Prisma 2 release, the issue with
enum: { not: { equals: { value } }
is now gone and theJsonFilter
input is now working well.input JsonFilter { equals: JSON not: JSON }
-
In some nested inputs, the
XYZWhereInput
were replaced byXYZRelationFilter
, so you need to update your client queries to use the newis
andisNot
syntax.