Skip to content

Bug: Props in child component defined in mixin are missing with shallowMount on @vue/compat #2333

Open
@cody-collins

Description

@cody-collins

Describe the bug
With shallowMount on Vue 3 + @vue/compat, properties of a child component are undefined when using them through a mixin.

If the property is moved from the mixin directly to the component, then the property is defined.

Also if the shallowMount is switched to mount, the property is defined.

To Reproduce

I created a demo repo where this issue can be reproduced, with tags for various working and not working states. It includes the following important files:

git clone https://github.com/cody-collins/vue-compat-mixin-demo.git
cd vue-compat-mixin-demo
npm install
npm test

And the following tags:

Expected behavior
The second assertion should pass in the broken case

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions