这是我的 package.json 文件。
{
"name": "moneymall",
"version": "1.0.0",
"description": "A money mall server app.",
"main": "index.js",
"author": "Anbu Selvan",
"license": "ISC",
"keywords": [],
"dependencies": {
"body-parser": "^1.18.3",
"cors": "^2.8.5",
"e": "0.0.4",
"express": "^4.16.4",
"mysql": "^2.16.0",
"pug": "^2.0.3",
"yarn": "^1.15.2"
},
"devDependencies": {
"nodemon": "^1.18.10",
"react-scripts": "^2.1.8"
}
}
Run Code Online (Sandbox Code Playgroud)
运行yarn build并出现此错误。
纱线运行 v1.15.2 错误 找不到命令“build”。信息 请访问 https://yarnpkg.com/en/docs/cli/run以获取有关此命令的文档
script.build您的文件中似乎没有定义密钥package.json。使用库进行构建的示例条目webpack为:
"scripts": {
"build": "webpack"
}
Run Code Online (Sandbox Code Playgroud)