Skip to content

Conversation

@xanf
Copy link
Collaborator

@xanf xanf commented Nov 16, 2021

Vue 3.x keeps the behaviour we've had in Vue2: all unknown fields in component are passed as $options. This allows you to do following:

createApp({ ...App, test: 123 }).mount("#app");

and access test on this.$options.test
While not in a great use in modern Vue 3 code, this is still a great importance when we work with @vue/compat - you are still want to be able to pass router/store/etc. in "legacy" way to your component

This PR restores this behavior

@xanf xanf force-pushed the mount-other-options branch from 3d2f9b2 to 975c2bf Compare November 16, 2021 18:45
Copy link
Member

@afontcu afontcu left a comment

Choose a reason for hiding this comment

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

nice catch!

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.

4 participants