Skip to content

fix(runtime-utils): setProps can replace array prop#877

Merged
danielroe merged 2 commits intonuxt:mainfrom
tomoki1207:main
Jul 1, 2024
Merged

fix(runtime-utils): setProps can replace array prop#877
danielroe merged 2 commits intonuxt:mainfrom
tomoki1207:main

Conversation

@tomoki1207
Copy link
Contributor

Use custom merge function via createDefu at setProps() to replace prop that has array type.
Because defu() concats array instead of overwrite in default behavior. (Link)

Will concat array values (if default property is defined)

Fix: #876

@dosubot dosubot bot added size:M This PR changes 30-99 lines, ignoring generated files. bug Something isn't working labels Jun 28, 2024
@tomoki1207
Copy link
Contributor Author

@danielroe Could you review this PR or assign someone?

If I have to do any action to contribute for this repository, please tell me about it.

@danielroe danielroe self-requested a review June 30, 2024 15:55
@dosubot dosubot bot added the lgtm This PR has been approved by a maintainer label Jul 1, 2024
@danielroe danielroe merged commit a393b3e into nuxt:main Jul 1, 2024
@github-actions github-actions bot mentioned this pull request Jul 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working lgtm This PR has been approved by a maintainer size:M This PR changes 30-99 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

setProps with array concats newItems and oldItems value

2 participants