vite: Vite Installation failing
Describe the bug
I am installing Vite.Js within docker container with linux image.
Packages fail to resolve. Assume the latest version of rollup is impoacting
error Couldn’t find package “@rollup/rollup-freebsd-arm64@4.24.1” required by “rollup@^4.2.0” on the “npm” registry.
Reproduction
https://stackblitz.com/edit/vitejs-vite-tfhk5m?file=package.json&terminal=dev
Steps to reproduce
Run npm install vite.js
“dev”: “vite”, “build”: “tsc && vite build”,
System Info
System:
OS: macOS 13.7
CPU: (8) x64 Intel(R) Core(TM) i7-7700HQ CPU @ 2.80GHz
Memory: 42.40 MB / 16.00 GB
Shell: 5.9 - /bin/zsh
Binaries:
Node: 18.15.0 - /usr/local/bin/node
Yarn: 1.22.19 - /usr/local/bin/yarn
npm: 9.5.0 - /usr/local/bin/npm
Watchman: 2023.03.06.00 - /usr/local/bin/watchman
Browsers:
Chrome: 130.0.6723.70
Safari: 18.0.1
Used Package Manager
yarn
Logs
No response
Validations
- Follow our Code of Conduct
- Read the Contributing Guidelines.
- Read the docs.
- Check that there isn’t already an issue that reports the same bug to avoid creating a duplicate.
- Make sure this is a Vite issue and not a framework-specific issue. For example, if it’s a Vue SFC related bug, it should likely be reported to vuejs/core instead.
- Check that this is a concrete bug. For Q&A open a GitHub Discussion or join our Discord Chat Server.
- The provided reproduction is a minimal reproducible example of the bug.
About this issue
- Original URL
- State: closed
- Created 2 years ago
- Reactions: 21
- Comments: 20 (1 by maintainers)
temp fix: add
to your package.json
This worked
It’s happening to everyone. Add to package.json temporarily
this works …
The issues seems to be resolving with temporary fix in package.json by downgrading rollup to earlier version.
Rollup had a fix for freebsd and seems this is causing the problem for vite when yarn is used.
Switch to temp npm install
“scripts”: { “dev”: “vite”, “build”: “tsc && vite build”, “start”: “vite preview”, “lint”: “eslint ./src”,
Rollup issues rasied already for the same. : https://github.com/rollup/rollup/issues/5704
This works just fine in vite but this issue really needs fixing
Same issue. Fixed with: for yarn
for pnpm
this is also suddenly happened in my GitHub workflow