Skip to content

Conversation

GuillaumeGuerinPP
Copy link
Contributor

The rule vue/require-default-prop return an error for all optional props when using withDefaults and a spread operator as second argument

image

The rule seems to return an empty object if something different from Property is found. Ignoring it instead will allow the check for at least props defined in the file

Copy link
Member

@FloEdelmann FloEdelmann left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the fix! Could you please add one valid and one invalid test case to to the rule tests?

@GuillaumeGuerinPP
Copy link
Contributor Author

GuillaumeGuerinPP commented Apr 26, 2024

Thanks for the fix! Could you please add one valid and one invalid test case to to the rule tests?

Thanks for your quick answer 🙌 Test added here : edceab2

Copy link
Member

@FloEdelmann FloEdelmann left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice, looks good to me!

@FloEdelmann FloEdelmann requested a review from ota-meshi April 26, 2024 11:33
Copy link
Member

@ota-meshi ota-meshi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! Thank you!

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.

3 participants