每当我运行yarn dev
或npm run dev
时,我都会遇到这个问题:
yarn run v1.22.10
warning ../../../../package.json: No license field
$ next dev
ready - started server on 0.0.0.0:3000, url: http://localhost:3000
info - Using webpack 5. Reason: no next.config.js https://nextjs.org/docs/messages/webpack5
event - compiled successfully
event - build page: /
wait - compiling...
error Command failed with signal "SIGSEGV".
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
字符串package.json
:
{
"name": "nextjs",
"version": "0.1.0",
"private": true,
"scripts": {
"dev": "next dev",
"build": "next build",
"start": "next start"
},
"dependencies": {
"next": "^10.2.3",
"react": "17.x",
"react-dom": "17.x",
"webpack": "^5.39.1"
},
"devDependencies": {
"webpack-cli": "^4.7.2"
}
}
型
3条答案
按热度按时间6tqwzwtp1#
正如@Fernando Gomes评论的那样,似乎是Mac M1的问题。
为了让它在我的环境中工作,我使用 Docker,参数如下:
字符串
6kkfgxo02#
要解决这个问题,首先做一个清洁:
字符串
然后
型
xghobddn3#
在我的情况下是一个问题的无线网络:?.我知道是奇怪的关闭无线网络,一切都开始工作。