【问题标题】:error .../node_modules/coa: Command failed [duplicate]错误.../node_modules/coa:命令失败[重复]
【发布时间】:2021-12-18 18:18:34
【问题描述】:

我在尝试通过 Vue-cli vue create project 创建 vue3 的应用程序时遇到以下错误

✨  Creating project in /home/iraj/works/project.
⚙️  Installing CLI plugins. This might take a while...

yarn install v1.22.17
info No lockfile found.
[1/4] Resolving packages...
[2/4] Fetching packages...
[3/4] Linking dependencies...
[4/4] Building fresh packages...
[1/4] ⠄ core-js
[2/4] ⠄ coa
[3/4] ⠄ ejs
error /home/iraj/works/project/node_modules/coa: Command failed.
Exit code: 1
Command: start /B node compile.js & node compile.js
Arguments: 
Directory: /home/iraj/works/project/node_modules/coa
Output:
/bin/sh: 1: start: not found
node:internal/modules/cjs/loader:936
  throw err;
  ^

Error: Cannot find module '/home/iraj/works/project/node_modules/coa/compile.js'
    at Function.Module._resolveFilename (node:internal/modules/cjs/loader:933:15)
    at Function.Module._load (node:internal/modules/cjs/loader:778:27)
    at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:81:12)
    at node:internal/main/run_main_module:17:47 {
  code: 'MODULE_NOT_FOUND',
  requireStack: []
}



 ERROR  command failed: yarn 

我正在使用的工具:

  System:
    OS: Linux 5.11 Ubuntu 20.04.3 LTS (Focal Fossa)
    CPU: (8) x64 Intel(R) Core(TM) i7-4702MQ CPU @ 2.20GHz
  Binaries:
    Node: 17.0.1 - /usr/local/bin/node
    Yarn: 1.22.17 - /usr/local/bin/yarn
    npm: 8.1.2 - /usr/local/bin/npm
  Browsers:
    Chrome: Not Found
    Firefox: 93.0
  npmGlobalPackages:
    @vue/cli: 4.5.15

【问题讨论】:

  • 谢谢队友,是的,同样的错误。

标签: node.js vue.js npm vue-cli


【解决方案1】:

COA 遭到破坏,因此导致了此错误。检查https://github.com/veged/coa/issues/99

【讨论】:

    【解决方案2】:

    解决了。刚刚删除目录/home/iraj/works/project/node_modules/coa 并在Merge 模式下再次运行vue create project

    【讨论】:

      猜你喜欢
      • 2020-06-09
      • 2019-04-03
      • 2021-07-29
      • 1970-01-01
      • 2023-03-17
      • 2019-07-06
      • 2020-09-05
      • 2013-12-31
      • 1970-01-01
      相关资源
      最近更新 更多