Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

fix(build): build vue-compat in default exports mode #4460

Merged
merged 1 commit into from
Sep 7, 2021

Conversation

xanf
Copy link
Contributor

@xanf xanf commented Aug 27, 2021

f2fb8a5 introduced change in rollup configuration - output.exports for all packages was swapped from auto to named (to avoid warnings, I assume). Unfortunately this broke vue-compat commonJS package where single default export is expected to be spreaded so @vue/compat will be a drop-in replacement for vue.

Now, for example, when you require @vue/compat in node.js environment (for example when running vue-test-utils) you need to access defineComponent as require('@vue/compat').default.defineComponent instead of require('@vue/compat').defineComponent

Since @vue/compat is expected to serve as "drop-in" replacement for vue this PR is forcing output.expots = default for vue-compat package which is exactly the expected case - rollup expects single default export

@yyx990803 yyx990803 merged commit 7575733 into vuejs:master Sep 7, 2021
@yyx990803
Copy link
Member

yyx990803 commented Sep 7, 2021

Merged too fast - follow up in 22a9b37

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