question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Cannot run dev on windows: yarn dev

See original GitHub issue

I have clone this repo and yarn dev just not working:

F:\work\projects\quini\vite-vitesse-2\vueuse>node --version
v15.5.1

F:\work\projects\quini\vite-vitesse-2\vueuse>yarn --version
1.22.10

F:\work\projects\quini\vite-vitesse-2\vueuse>yarn list vite
yarn list v1.22.10
warning Filtering by arguments is deprecated. Please use the pattern option instead.
└─ vite@2.0.1
Done in 0.68s.

F:\work\projects\quini\vite-vitesse-2\vueuse>yarn list vue
yarn list v1.22.10
warning Filtering by arguments is deprecated. Please use the pattern option instead.
└─ vue@3.0.5
Done in 0.68s.

Install dependencies:

F:\work\projects\quini\vite-vitesse-2\vueuse>yarn install
yarn install v1.22.10
[1/4] Resolving packages...
[2/4] Fetching packages...
warning Pattern ["vue-demi@latest"] is trying to unpack in the same destination "C:\\Users\\userquin\\AppData\\Local\\Yarn\\Cache\\v6\\npm-vue-demi-0.6.0-e314282f704cb449119b9fd002cbbc0e39f591fe-integrity\\node
_modules\\vue-demi" as pattern ["vue-demi@^0.6.0","vue-demi@^0.6.0"]. This could result in non-deterministic behavior, skipping.
info fsevents@2.1.3: The platform "win32" is incompatible with this module.
info "fsevents@2.1.3" is an optional dependency and failed compatibility check. Excluding it from installation.
info fsevents@2.3.1: The platform "win32" is incompatible with this module.
info "fsevents@2.3.1" is an optional dependency and failed compatibility check. Excluding it from installation.
info fsevents@2.3.2: The platform "win32" is incompatible with this module.
info "fsevents@2.3.2" is an optional dependency and failed compatibility check. Excluding it from installation.
[3/4] Linking dependencies...
warning " > @rollup/plugin-typescript@8.2.0" has unmet peer dependency "tslib@*".
warning " > @vue/test-utils@1.1.3" has incorrect peer dependency "vue@2.x".
warning " > @vue/test-utils@1.1.3" has unmet peer dependency "vue-template-compiler@^2.x".
warning " > babel-loader@8.2.2" has unmet peer dependency "webpack@>=2".
warning " > esbuild-register@2.0.0" has unmet peer dependency "esbuild@>=0.8.31".
warning " > rollup-plugin-uglify@6.0.4" has incorrect peer dependency "rollup@>=0.66.0 <2".
warning " > vite-plugin-components@0.6.12" has unmet peer dependency "vite@^2.0.0-beta.69".
warning " > vite-plugin-icons@0.2.2" has unmet peer dependency "@vue/compiler-sfc@^3.0.2".
warning "vitepress > @docsearch/js > @docsearch/react@1.0.0-alpha.28" has unmet peer dependency "react@^16.8.0".
warning "vitepress > @docsearch/js > @docsearch/react@1.0.0-alpha.28" has unmet peer dependency "react-dom@^16.8.0".
warning " > @vue/composition-api@1.0.0-rc.2" has incorrect peer dependency "vue@>= 2.5 < 3".
warning " > @vueuse/router@4.2.0-beta.2" has unmet peer dependency "vue-router@>=4.0.0-rc.1".
warning " > @vueuse/rxjs@4.2.0-beta.2" has unmet peer dependency "rxjs@>=6.0.0".
[4/4] Building fresh packages...
success Saved lockfile.
$ patch-package
patch-package 6.2.2
Applying patches...
No patch files found
Done in 107.79s.

and starting vitepress:

F:\work\projects\quini\vite-vitesse-2\vueuse>yarn dev
yarn run v1.22.10
$ nr docs
$ vitepress dev packages
vitepress v0.12.2
vite v2.0.1
(!) "alias" option is deprecated. Use "resolve.alias" instead.
Pre-bundling dependencies:
  qrcode
  nprogress
  tslib
  js-yaml
  dayjs
  (...and 3 more)
(this will be run only when your dependencies or config have changed)

 ⚡ Vite dev server running at:

  > Network:  http://192.168.1.37:3000/
  > Local:    http://localhost:3000/
  > Network:  http://172.17.94.17:3000/
[@vue/compiler-sfc] <script setup> is still an experimental proposal.
Follow its status at https://github.com/vuejs/rfcs/pull/227.

[@vue/compiler-sfc] When using experimental features,
it is recommended to pin your vue dependencies to exact versions to avoid breakage.

11:28:02 [vite] new dependencies found: vue-chemistry/boolean, updating...
11:28:02 [vite] ✨ dependencies updated, reloading page...
11:28:02 [vite] Internal server error: Failed to resolve entry for package "@vueuse/core". The package may have incorrect main/module/exports specified in its package.json.
  Plugin: vite:import-analysis
  File: F:/work/projects/quini/vite-vitesse-2/vueuse/packages/.vitepress/theme/components/DarkModeSwitch.vue
      at resolvePackageEntry (F:\work\projects\quini\vite-vitesse-2\vueuse\node_modules\vite\dist\node\chunks\dep-d13406fa.js:34262:15)
      at tryNodeResolve (F:\work\projects\quini\vite-vitesse-2\vueuse\node_modules\vite\dist\node\chunks\dep-d13406fa.js:34102:11)
      at Context.resolveId (F:\work\projects\quini\vite-vitesse-2\vueuse\node_modules\vite\dist\node\chunks\dep-d13406fa.js:33985:28)
      at Object.resolveId (F:\work\projects\quini\vite-vitesse-2\vueuse\node_modules\vite\dist\node\chunks\dep-d13406fa.js:45841:55)
      at runMicrotasks (<anonymous>)
      at processTicksAndRejections (node:internal/process/task_queues:93:5)
      at async TransformContext.resolve (F:\work\projects\quini\vite-vitesse-2\vueuse\node_modules\vite\dist\node\chunks\dep-d13406fa.js:45646:23)
      at async normalizeUrl (F:\work\projects\quini\vite-vitesse-2\vueuse\node_modules\vite\dist\node\chunks\dep-d13406fa.js:47179:34)
      at async TransformContext.transform (F:\work\projects\quini\vite-vitesse-2\vueuse\node_modules\vite\dist\node\chunks\dep-d13406fa.js:47318:57)
      at async Object.transform (F:\work\projects\quini\vite-vitesse-2\vueuse\node_modules\vite\dist\node\chunks\dep-d13406fa.js:45898:30)
11:28:21 [vite] Internal server error: Failed to resolve entry for package "@vueuse/core". The package may have incorrect main/module/exports specified in its package.json.
  Plugin: vite:import-analysis
  File: F:/work/projects/quini/vite-vitesse-2/vueuse/packages/.vitepress/theme/components/DarkModeSwitch.vue
      at resolvePackageEntry (F:\work\projects\quini\vite-vitesse-2\vueuse\node_modules\vite\dist\node\chunks\dep-d13406fa.js:34262:15)
      at tryNodeResolve (F:\work\projects\quini\vite-vitesse-2\vueuse\node_modules\vite\dist\node\chunks\dep-d13406fa.js:34102:11)
      at Context.resolveId (F:\work\projects\quini\vite-vitesse-2\vueuse\node_modules\vite\dist\node\chunks\dep-d13406fa.js:33985:28)
      at Object.resolveId (F:\work\projects\quini\vite-vitesse-2\vueuse\node_modules\vite\dist\node\chunks\dep-d13406fa.js:45841:55)
      at processTicksAndRejections (node:internal/process/task_queues:93:5)
      at async TransformContext.resolve (F:\work\projects\quini\vite-vitesse-2\vueuse\node_modules\vite\dist\node\chunks\dep-d13406fa.js:45646:23)
      at async normalizeUrl (F:\work\projects\quini\vite-vitesse-2\vueuse\node_modules\vite\dist\node\chunks\dep-d13406fa.js:47179:34)
      at async TransformContext.transform (F:\work\projects\quini\vite-vitesse-2\vueuse\node_modules\vite\dist\node\chunks\dep-d13406fa.js:47318:57)
      at async Object.transform (F:\work\projects\quini\vite-vitesse-2\vueuse\node_modules\vite\dist\node\chunks\dep-d13406fa.js:45898:30)
      at async transformRequest (F:\work\projects\quini\vite-vitesse-2\vueuse\node_modules\vite\dist\node\chunks\dep-d13406fa.js:61468:29)
¿Desea terminar el trabajo por lotes (S/N)? s

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:19 (19 by maintainers)

github_iconTop GitHub Comments

1reaction
antfucommented, Feb 21, 2021

Should be fixed in the latest commits.

1reaction
YunYouJuncommented, Feb 21, 2021

I think there is some edge case of Vite not awaring of linked packages in monorepo, you can try to yarn build and then try yarn dev?

I have tried this, but no work.

It seems that only DemoContainer is not loaded properly. Other content works well.

DemoContainer is imported and autoloaded by vite-plugin-components. Is it related to this? Will there be a conflict between them?

https://github.com/vueuse/vueuse/blob/5941b6a64e556846d4f8492d4215c460febc4881/packages/.vitepress/theme/index.ts#L3

https://github.com/vueuse/vueuse/blob/5941b6a64e556846d4f8492d4215c460febc4881/packages/vite.config.ts#L42

Read more comments on GitHub >

github_iconTop Results From Across the Web

yarn run dev is not working · Issue #1330 · sharetribe/ftw-daily
Followed all the steps but the "yarn run dev" command failed. Maybe i need an other version of the "jose" package? I'm working...
Read more >
when I hit yarn run dev . it shows 'next' is not recognized as an ...
Then when I tried to run this command yarn dev It shows the error next is not recognized as an internal or external...
Read more >
Fix Unable to Run Yarn in Windows Terminal - PowerShell
To fix it, open PowerShell as administrator, again make sure to run this in PowerShell, not with the regular command prompt (cmd). Copy...
Read more >
npm, pnpm, and Yarn | IntelliJ IDEA Documentation - JetBrains
IntelliJ IDEA integrates with the npm, Yarn, Yarn 2, and pnpm, so you can install, locate, update, and remove packages of reusable code...
Read more >
yarn: command not found error [Solved] | bobbyhadz
To solve the error "yarn: command not found", install the yarn package globally by running npm install -g yarn and restart your terminal....
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found