-
-
Notifications
You must be signed in to change notification settings - Fork 45
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Part of zod methods are not available after import #25
Comments
I made changes (https://github.com/lunacrafts/prisma-zod-generator/commit/292d4ccccec180f210b70c732a3f447a246c4636) after which I'm able to make: |
Hey @lunacrafts Also, do you think there are any side effects to exporting the schema and the type like that? |
Hello @omar-dulaimi First of all, my changes broke other part of your package, so at some point I had to resign from it (and from prisma as well), so unfortunately I'm not able to make and test PR. Second of all, in the meantime I figured out my approach with type infering from zod would use a lot of memory during development so It's no-go solution. I don't know in-depth zod API so I'm not going to be helpful in any matter. |
Sad to hear that @lunacrafts There are alternatives to zod, like joi, yup and class validator. Maybe they could be useful to your case. |
The real issue for me was prisma. Im in the phase of prototyping application (with mongodb) and Prisma hold me back in this case. It's great for CRUD and basic database operations, but I couldn't really use core features of mongo. I really appreciated using prisma + prisma-zod-generator + trpc + next but I run into some limitations what made this setup of tools kinda useless. One of those is that I was able to generate awesome end-to-end typesafe queries, but I wasn't able to intercept anywhere on the backend side, so for example I couldn't apply access-control rules to resources. It is awesome, but just not in my use case! Really appreciate your work on this package and I'm sure I'll use it in another part of project but just not yet. |
Bug description
inside of ModelCreateInputObjectSchema file, I can see those properties.
but after I import it It's undefined
The text was updated successfully, but these errors were encountered: