fix(drag-handle-vue-2): fix vue2 warnign about objects as default#6857
Merged
bdbch merged 2 commits intoueberdosis:developfrom Sep 3, 2025
Merged
Conversation
Vue2 requires factory functions for defaults for objects and arrays. Prevent the warning > Invalid default value for prop "PluginKey": Props with type Object/Array must use a factory function to return the default value. Signed-off-by: Max <max@nextcloud.com>
🦋 Changeset detectedLatest commit: a706e4c The changes in this PR will be included in the next version bump. This PR includes changesets to release 69 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
✅ Deploy Preview for tiptap-embed ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
Contributor
Author
|
I tried to access The only ways for fixing the other error I see are:
|
bdbch
approved these changes
Sep 3, 2025
Contributor
|
@bdbch thanks for merging the PR. Would you consider to backport it to the |
bdbch
added a commit
that referenced
this pull request
Oct 23, 2025
) * fix(drag-handle-vue-2): use factory function for default Vue2 requires factory functions for defaults for objects and arrays. Prevent the warning > Invalid default value for prop "PluginKey": Props with type Object/Array must use a factory function to return the default value. Signed-off-by: Max <max@nextcloud.com> * Fix prop default handling for Vue 2 --------- Signed-off-by: Max <max@nextcloud.com> Co-authored-by: bdbch <6538827+bdbch@users.noreply.github.com>
Member
|
Released as |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Changes Overview
classmay not be used as prop.Implementation Approach
Use a factory function.
Testing Done
Checked that it prevents the warning by building text with it:
Verification Steps
Actually testing is cumbersome. Vue 3 seems to have dropped the warning. I'm still checking if that actually also means it's not an issue anymore.
Checking the code and checking the docs is probably best (search for 'factory function')
Additional Notes
I'm still looking into fixing the class reserved name warning.
Checklist
Related Issues
Initially came up in nextcloud/text#7537 (comment)