-
Notifications
You must be signed in to change notification settings - Fork 533
feat: add isOptionalProperty method to ObjectShapeType #4329
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
Conversation
What's your use case? Also, take a look where the ConstantArrayType method is used, and think about whether we're missing something with ObjectShapeType or not.
751fe71
to
c131109
Compare
I don't have a specific use case, I just saw this on the array type and thought it might clean up all the in_array
calls, if you'd rather not have it then feel free to close
Also, take a look where the ConstantArrayType method is used, and think about whether we're missing something with ObjectShapeType or not.
I'm not sure what you're trying to get at here, it looks like isOptionalKey()
is used in several places like when building a new array
Hello!
While I was digging around, I noticed that the ConstantArrayType has a similar method and figured it would be nice to have here as well.
Thanks!