sitaram
PPrisma
•Created by sitaram on 1/15/2025 in #help-and-questions
TypeScript issue with JSON[] field filter using path
I have the following model and am using a PostgreSQL database:
model Message { mentions Json[] }I am using
prisma-json-types-generator
to generate the types. For the mentions
field, the generator produced a type NullableListFilter
that does not have the path method.
When trying to filter on message
with a path using prisma.message.findMany
, I am getting the TypeScript error: Object literal may only specify known properties, and 'path' does not exist in type 'NullableListFilter<PrismaJson.Message>'.
Any thoughts on this issue are appreciated.7 replies