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

No matching export in "node_modules/vue/dist/vue.runtime.esm-bundler.js" for import "effectScope" #590

Closed
thespacedeck opened this issue Jul 29, 2021 · 3 comments

Comments

@thespacedeck
Copy link

thespacedeck commented Jul 29, 2021

Reproduction

I have following config:

"dependencies": {
    "pinia": "^2.0.0-beta.5",
    "vue": "^3.1.5"
  },
  "devDependencies": {
    "@vitejs/plugin-vue": "^1.3.0",
    "@vue/compiler-sfc": "^3.0.5",
    "autoprefixer": "^10.2.5",
    "postcss": "^8.3.0",
    "tailwindcss": "^2.2.2",
    "typescript": "^4.3.2",
    "vite": "^2.4.4",
    "vue-tsc": "^0.2.2"
  }

main.ts

import { createApp } from "vue";
import App from "./App.vue";
import { store } from "./store";

createApp(App)
  .use(store)
  .mount("#app");

store/index.ts

import { createPinia } from "pinia";
const store = createPinia();

export {
  store
};

Steps to reproduce the behavior

  1. $ npm i
  2. $ npm run dev

Expected behavior

Vue results in error:

error when starting dev server:
Error: Build failed with 1 error:
node_modules/pinia/dist/pinia.esm-browser.js:6:31: error: No matching export in "node_modules/vue/dist/vue.runtime.esm-bundler.js" for import "effectScope"
    at failureErrorWithLog (/......./node_modules/esbuild/lib/main.js:1449:15)
    at /......./node_modules/esbuild/lib/main.js:1131:28
    at runOnEndCallbacks (/......./node_modules/esbuild/lib/main.js:921:63)
    at buildResponseToResult (/......./node_modules/esbuild/lib/main.js:1129:7)
    at /......./node_modules/esbuild/lib/main.js:1236:14
    at /......./node_modules/esbuild/lib/main.js:609:9
    at handleIncomingPacket (/......./node_modules/esbuild/lib/main.js:706:9)
    at Socket.readFromStdout (/......./node_modules/esbuild/lib/main.js:576:7)
    at Socket.emit (events.js:314:20)
    at Socket.EventEmitter.emit (domain.js:483:12)

Are the vue an Pina version not compatible...? Any help would be appreciated here.

Kind Regards,
Wzz

@thalesagapito
Copy link

The effectScope API was just recently introduced (vuejs/core#2195). Try updating your vue version to at least ^3.2.0

@posva
Copy link
Member

posva commented Jul 29, 2021

I explained this in the changelog 😉

@posva posva closed this as completed Jul 29, 2021
@posva
Copy link
Member

posva commented Jul 30, 2021

As some might come across this by simply installing Pinia for the first time, I created #592. Comment there if you think anything is missing.

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

No branches or pull requests

3 participants