错误运行npm i时出错(退出代码1):离子错误 [英] ERROR An error occurred while running npm i (exit code 1): Ionic Error

查看:2596
本文介绍了错误运行npm i时出错(退出代码1):离子错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我开始研究离子,我对此非常陌生,并且遵循



谢谢,

解决方案

花了一天以上我遇到了很多解决方案, h如下所示


  1. 一些开发人员解决了这个问题,
    我将节点从v8降级到v7 .6.0并且离线CLI似乎都能正常工作。 From Here 但这个解决方案对我不起作用。


  2. 将命令行作为管理运行,此解决方案很有用


  3. 正确和良好的解决方案对我来说,是通过以下命令安装安装所有node-gyp依赖

      $ npm install --global --production windows-build-tools 

    然后安装软件包

      $ npm install --global node-gyp 


解决方案链接


I started working on ionic, i am totally new to this, and following This tutorials , i know this type of question already asked but not have proper solution to it, please provide solution to it, step i followed as,

1.Node installed - node-v8.9.0-x86
2. ran command npm install -g cordova ionic

npm WARN deprecated node-uuid@1.4.8: Use uuid module instead
C:\Users\Android1\AppData\Roaming\npm\cordova -> 
C:\Users\Android1\AppData\Roaming\npm\node_modules\cordova\bin\cordova
C:\Users\Android1\AppData\Roaming\npm\ionic -> 
C:\Users\Android1\AppData\Roaming\npm\node_modules\ionic\bin\ionic
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.1.2 
(node_modules\ionic\node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for 
fsevents@1.1.2: wanted {"os":"darwin","arch":"any"} (current: 
{"os":"win32","arch":"ia32"})

+ cordova@7.1.0
+ ionic@3.16.0
added 115 packages and updated 2 packages in 69.815s

  1. Then ran command ionic start myApp tabs , got following Error

Thank you,

解决方案

After spending more than day i came across many solutions, which are as follow

  1. Some developers solve this problem by, i downgraded node from v8 to v7.6.0 and all seems to work fine with ionic CLI. From Here but this solution not work for me.

  2. Run Command Line as Administrative, this solution is beneficial

  3. The Correct and well solution work for me, is to install install all node-gyp dependencies by following command

     $ npm install --global --production windows-build-tools
    

    and then install the package

     $ npm install --global node-gyp
    

Solution Link

这篇关于错误运行npm i时出错(退出代码1):离子错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆