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

Revert: deprecating this.$helper.object.clone #6479

Merged

Conversation

distantnative
Copy link
Member

Description

Summary of changes

  • Undeprecate $helper.object.clone
  • Use $helper.object.clone instead of structuredClone

Reasoning

structuredClone cannot handle the automatic reactivity layer that Vue 3 adds on most/all objects. So we need a beefier version of $helper.object.clone to solve this. But therefore, we should stick to using the helper everywhere.

Changelog

Fix

  • $helper.object.clone is no longer deprecated. Please use it instead of structuredClone as this might cause issues down the road with Vue 3.

Ready?

  • Tests and checks all pass

@distantnative distantnative added the type: refactoring ♻️ Is about bad code; cleans up code label Jun 9, 2024
@distantnative distantnative added this to the 5.0.0-alpha.1 milestone Jun 9, 2024
@distantnative distantnative self-assigned this Jun 9, 2024
@distantnative distantnative marked this pull request as ready for review June 9, 2024 09:08
@distantnative distantnative requested a review from a team June 9, 2024 09:08
Copy link
Member

@bastianallgeier bastianallgeier left a comment

Choose a reason for hiding this comment

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

Sometimes I really just hate all the reactivity parts for exactly those kind of quirks.

@bastianallgeier bastianallgeier merged commit 5f81c72 into v5/develop Jun 10, 2024
4 checks passed
@bastianallgeier bastianallgeier deleted the v5/refactor/revert-helper-clone-deprecated branch June 10, 2024 10:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: refactoring ♻️ Is about bad code; cleans up code
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants