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

fix(types): require function default value in withDefaults macro only for objects and arrays #4945

Conversation

JensDll
Copy link
Contributor

@JensDll JensDll commented Nov 14, 2021

I saw an issue coming up in 4868 and it seems to be related to a type problem in the withDefaults function. Default values for props containing null (union or directly) are required to be given in function form but should be treated like other primitives.

Playground link with reproduction

@JensDll JensDll closed this Nov 15, 2021
@JensDll JensDll deleted the fix-types-infer-defaults-with-null-values branch November 15, 2021 00:59
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

Successfully merging this pull request may close these issues.

1 participant