You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi, I need to build my project as library (micro component) to integrate it inside another project. Both projects is written in Vue 3.2.33 and my small micro component has to use Vue from its parent project. In case of vue.config.js it can be solved by this code.
if (process.env.VUE_APP_MODE !== 'development') {
externals.vue = 'esm!Vue3'
}
I tried to use, as it works with vue cli (pinia of the same version 2.0.32)
but there is an error connected with pinia. The project cannot be built without vue: RollupError: "getCurrentInstance" is not exported by "node_modules/pinia/node_modules/vue-demi/lib/index.mjs", imported by "node_modules/pinia/dist/pinia.mjs".
So the question is how to built project without errors and inside built one use external Vue (load using the “esm!” plugin) from parent project 'esm!Vue 3'
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Hi, I need to build my project as library (micro component) to integrate it inside another project. Both projects is written in Vue 3.2.33 and my small micro component has to use Vue from its parent project. In case of vue.config.js it can be solved by this code.
I tried to use, as it works with vue cli (pinia of the same version 2.0.32)
but there is an error connected with pinia. The project cannot be built without vue:
RollupError: "getCurrentInstance" is not exported by "node_modules/pinia/node_modules/vue-demi/lib/index.mjs", imported by "node_modules/pinia/dist/pinia.mjs".
In case of using
It does not work also.
So the question is how to built project without errors and inside built one use external Vue (load using the “esm!” plugin) from parent project 'esm!Vue 3'
Beta Was this translation helpful? Give feedback.
All reactions