Cordova Error: Your ios platform does not have Api.js

I’m trying to build a cordova ios app but not having much luck and getting strange errors.

Using this version of Cordova with older version of cordova-ios is
deprecated. Upgrade to cordova-ios@4.0.0 or newer.

Error: Your ios platform does not have Api.js

The first warning says my cordov-ios version is old, which is strange as this is my output:

$ cordova --version
7.0.1



$ cordova platform version ios

Installed platforms:
  ios 4.4.0
Available platforms: 
  android ~6.2.2
  blackberry10 ~3.8.0 (deprecated)
  browser ~4.1.0
  osx ~4.0.1
  webos ~3.7.0

So I clearly have the latest versions necessary.

And then the Api.js error. What is causing this?

Error: Your ios platform does not have Api.js

Any ideas?

Miner Asked on May 18, 2017 in General Stack.
Add Comment


  • LATEST ANSWERS

  • 2 Answer(s)

    Hi,

    Did you figure out what the problem was or did anyone answer you? We’re experiencing a similar problem and tried upgrading node.js and removing/adding the platform again with no luck.

    Thanks!

    Default Answered on June 4, 2017.
    Add Comment

    I was having exactly this problem but managed to solve it by simply removing and then adding the IOS platform within my project:

    cordova platform rm ios
    cordova platform add ios
    

    This seemed to fix whatever had somehow got broken when updating Cordova…

    Miner Answered on June 5, 2017.
    Add Comment

    Write your answer

    By posting your answer, you agree to the privacy policy and terms of service.