Skip to content

Conversation

adamberecz
Copy link

After investigating the issue down to @vue/runtime-core it appears that exposeProxy is only set in a script-setup component if it uses at least one directive:
https://github.com/vuejs/core/blob/main/packages/runtime-core/src/component.ts#L1187
https://github.com/vuejs/core/blob/main/packages/runtime-core/src/directives.ts#L143

Meaning a component can have an exposed API while exposeProxy is null. In this case we can create manually from exposed which essentially has the same effect, because the one created by runtime-core is only different by also proxying publicPropertiesMap which aren't available anyway.

Copy link

netlify bot commented Sep 30, 2025

Deploy Preview for vue-test-utils-docs ready!

Name Link
🔨 Latest commit eb826a7
🔍 Latest deploy log https://app.netlify.com/projects/vue-test-utils-docs/deploys/68dbd3a202f4430007139177
😎 Deploy Preview https://deploy-preview-2715--vue-test-utils-docs.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

Copy link
Member

@cexbrayat cexbrayat 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 for looking into it. Would you mind adding a unit test that showcases that the issue no longer exists?

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.

2 participants