it.mobimentum.phonegapspinnerplugin插件不工作Ios离子

时间:2017-08-17 12:07:15

标签: ios cordova ionic-framework

  

不推荐使用此版本的Cordova和旧版本的cordova-ios。升级至cordova-ios@4.0.0或更新版本。

     

错误:您的ios平台没有Api.js

sh-3.2# cordova --version
7.0.1

sh-3.2# ionic cordova build ios
> ionic cordova prepare
✖ cordova prepare - failed!
[ERROR] An error occurred while running cordova prepare (exit code 1):


        Discovered plugin "it.mobimentum.phonegapspinnerplugin" in config.xml. Adding it to the project
        Failed to restore plugin "it.mobimentum.phonegapspinnerplugin" from config.xml. You might need to try adding it
        again. Error: Error: Registry returned 404 for GET on
        https://registry.npmjs.org/it.mobimentum.phonegapspinnerplugin

sh-3.2# cordova platform version ios
Installed platforms:
  android 5.2.2
  browser 4.1.0
  ios 4.4.0
Available platforms:
  blackberry10 ~3.8.0 (deprecated)
  osx ~4.0.1
  webos ~3.7.0

根据LuminousEagle的answer我试图通过

添加和删除平台
cordova platform rm ios
cordova platform add ios

再次运行命令

ionic cordova build ios

仍然有错误

sh-3.2# ionic cordova build ios
> ionic cordova prepare
✖ cordova prepare - failed!
[ERROR] An error occurred while running cordova prepare (exit code 1):


        Discovered plugin "it.mobimentum.phonegapspinnerplugin" in config.xml. Adding it to the project
        Failed to restore plugin "it.mobimentum.phonegapspinnerplugin" from config.xml. You might need to try adding it
        again. Error: Error: Registry returned 404 for GET on
        https://registry.npmjs.org/it.mobimentum.phonegapspinnerplugin

因此,名为“it.mobimentum.phonegapspinnerplugin”的插件未安装。

搜索了一下后我找到plugin github url 从用法部分我试图通过

安装插件
cordova plugin add https://github.com/mobimentum/phonegap-plugin-loading-spinner.git

仍显示错误

sh-3.2# cordova plugin add https://github.com/mobimentum/phonegap-plugin-loading-spinner.git
Error: Failed to fetch plugin https://github.com/mobimentum/phonegap-plugin-loading-spinner.git via registry.
Probably this is either a connection problem, or plugin spec is incorrect.
Check your connection and plugin name/version/URL.
Error: npm: Command failed with exit code 235 Error output:
npm ERR! addLocal Could not install /tmp/npm-2500-e6f21046/git-cache-49279488/feeaeb845cd544e5875d75ff21d0504e50d315a4
npm ERR! Darwin 16.7.0
npm ERR! argv "/usr/local/bin/node" "/usr/local/bin/npm" "install" "https://github.com/mobimentum/phonegap-plugin-loading-spinner.git" "--save"
npm ERR! node v6.11.1
npm ERR! npm  v3.10.10
npm ERR! code EISDIR
npm ERR! errno -21
npm ERR! syscall read

npm ERR! eisdir EISDIR: illegal operation on a directory, read
npm ERR! eisdir This is most likely not a problem with npm itself
npm ERR! eisdir and is related to npm not being able to find a package.json in
npm ERR! eisdir a package you are trying to install.

npm ERR! Please include the following file with any support request:
npm ERR!     /Users/plutus/Desktop/Croisiere-ios-3/node_modules/npm-debug.log

我找不到任何正确的方法来摆脱这个问题。

任何帮助将不胜感激,谢谢你提前。

0 个答案:

没有答案