adxvcasas
PPrisma
•Created by adxvcasas on 5/3/2024 in #help-and-questions
Type 'string[]' is not assignable to type 'string'.ts(2322) when trying to create a form using Prism
so I'm trying to create a submitForm using prisma, react-hook-form and zod and mysql as my database. But the problem I'm encountering right now is I get this error on form-submit.ts
Type 'string[]' is not assignable to type 'string'.ts(2322)
I know this comes from my schema.prisma, because upon reading the docs, on Scalar https://www.prisma.io/docs/orm/reference/prisma-schema-reference#-modifier
Since my zod accepts array.
form-submit.ts
3 replies