Skip to content
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

addModelFactoryDeclaration receives DMMF.DataModel #23

Open
toyamarinyon opened this issue Mar 26, 2023 · 0 comments
Open

addModelFactoryDeclaration receives DMMF.DataModel #23

toyamarinyon opened this issue Mar 26, 2023 · 0 comments

Comments

@toyamarinyon
Copy link
Owner

addModelFactoryDeclaration receives three arguments: sourceFile: SourceFile, model: DMMF.Model, and models: DMMF.Model[]. sourceFile is the file where the factory is created, and DMMF.Model represents a single model that is the target for creating a factory, such as Post or User. When additional elements defined in the schema, such as enums, are needed, it is necessary to add arguments. Therefore, instead of Model[], the entire schema, represented by DMMF.DataModel, is added as an argument.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant