-
-
Notifications
You must be signed in to change notification settings - Fork 40
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
Configuring converted schema to be either a type or an interface #307
Comments
It might be possible try changing this line to type and see what happens https://github.com/mrjono1/joi-to-typescript/blob/master/src/parse.ts#L161 |
Thanks, I will try this and let you know since I moved to some other issues. From the looks of it, that would work though. Can you please leave this open until I get back to this? Also, if that change would do it, will that be part of some update, or would there be some way to configure or "hack" it as it is from the Joi schema. |
How did you go? |
Hey Jono, Sorry for the wait. So I tried this now, changed the line inside I guess that it would need to be a bit more explicitly coded for that. |
That makes sense |
would you want everything to be a |
I guess it would be good to be configurable as an option/parameter for backwards compatibility at least. I am not sure if changing all existing |
Hi,
We are trying to solve this issue, and one way would be to use a type instead of an interface when defining strict types. Is there any way to configure
joi-to-typescript
to force the generation of atype
instead of aninterface
?Thanks
The text was updated successfully, but these errors were encountered: