无法运行包裹命令

时间:2019-03-21 01:50:07

标签: reactjs npm babel parceljs

我正在尝试包裹。我不断收到以下错误。

npm运行开始

  

frontend@1.0.0开始/ Users / laurasaydeh / Desktop / dragonstack / frontend   包裹index.html

sh:包裹:找不到命令 npm ERR!文件sh npm ERR!代码ELIFECYCLE npm ERR! errno ENOENT npm ERR! syscall产生 npm ERR! frontend@1.0.0开始:parcel index.html npm ERR!产生ENOENT npm ERR! npm ERR!在frontend@1.0.0启动脚本处失败。 npm ERR! npm可能不是问题。上面可能还有其他日志记录输出。

这是我的package.json文件

    {
  "name": "frontend",
  "version": "1.0.0",
  "description": "",
  "main": "index.js",
  "scripts": {
    "start": "parcel index.html"
  },
  "keywords": [],
  "author": "",
  "license": "ISC",
  "dependencies": {
    "react": "^16.8.4",
    "react-dom": "^16.8.4"
  },
  "devDependencies": {
    "babel-plugin-transform-class-properties": "^6.24.1",
    "babel-preset-env": "^1.7.0",
    "babel-preset-react": "^6.24.1"
  }
}

这是我的babelrc文件

{
    "presets": ["env", "react"],
    "plugins": ["transform-class-properties"]
}

我尝试清理缓存,删除节点模块后重新安装npm。 我也尝试过更改start命令来打包构建index.js。

我不知道为什么这不起作用

更新:我相信包裹根本没有安装。 Parcel not being intalled

0 个答案:

没有答案
相关问题