Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

NotificationGroup: fix extraneous non-props warning in Vue 3.5+ #49

Merged
merged 1 commit into from
Dec 5, 2024

Conversation

Nebual
Copy link
Contributor

@Nebual Nebual commented Sep 26, 2024

This change fixes a warning when used in Vue 3.5+.

Vue's devtools auto add a data-v-inspector prop to components as a form of Sourcemap.
As of Vue 3.5+, for NotificationGroup this was causing a warning of 'Extraneous non-props attributes ("data-v-inspector") were passed to component but could not be automatically inherited because component renders fragment or text root nodes.'

Similar to this Nuxt PR, this PR disables 'automatically inherit attributes', as by default in Vue extra attributes added to <NotificationGroup something="x"> would attempt to add something as an attribute on the root node, but NotificationGroup's root node is a <template> which can't receive attributes.

Vue's devtools auto add a data-v-inspector prop to components as a form of Sourcemap.
As of Vue 3.5+, for NotificationGroup this was causing a warning of 'Extraneous non-props attributes ("data-v-inspector") were passed to component but could not be automatically inherited because component renders fragment or text root nodes.'
@aidenmarkus
Copy link

Thank you! This will fix the issue we currently have.

Copy link
Owner

@emmanuelsw emmanuelsw left a comment

Choose a reason for hiding this comment

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

Thank you!

@emmanuelsw emmanuelsw merged commit 6ad4d0a into emmanuelsw:main Dec 5, 2024
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants