@ionic-native/file-transfer/index.d.ts, found version 4, expected 3

I had a similar issue. Is it me or did @ionic-native/transfer change to @ionic-native/file-transfer?
Once I got rid of transfer, I deleted the node_modules folder and did an npm install.
Had to make a few small code changes because some methods/objects are different in file-transfer.
Now I’m running 4.4.0 for all of them, and on angular 5

Sorry, I don’t know how to do that, should I just update my package.json file?

I’m having problem with screen-orientation plugin, in my package.json file I have:

   "@ionic-native/core": "4.3.2",
   "@ionic-native/screen-orientation": "^4.4.0",
   "@ionic-native/splash-screen": "4.3.2",
   "@ionic-native/status-bar": "4.3.2",

Should I change the version to exact “4.3.2” like the others?
Should I run something else after that?

yes the workaround was great.

What steps did you take to do this ?

I have the same problem with another plugin, tweaking versions didn’t help, but using corodva platform rm android and then cordova platform add android resolved the issue.

Here’s the definite solution:
Run npm install on your project. Npm will show a bunch of warnings of the unmet dependencies

all the dependencies that are listed are unmet, you have to downgrade/upgrade them. For me I changed the version of all the @ionic-native/<plugin_name> to the same version (4.3.3), and it worked!

Well I tried every stated solution but nothing worked for me directly. Actually combination of 2-3 above solutions stated worked for me.
So firstly, I was using android engine 6.3.0, so I used this command to remove it first:

ionic cordova rm android

Then, I re-installed the android platform by:

ionic cordova add android

By this, android engine of 7.1.3 installed in my environment.
Then I tried to build but I started getting errors that I don’t have gradle, so for that I installed gradle into my system (which is mac) by:

brew install gradle

After doing all of this, I tried to build again but then I started getting errors again saying Error: Metadata version mismatch for module, exist version 4 expected 3

For this error, I started going to each module which was giving me this error and I changed every something.metadata.json file’s version number 4 to version: 3.

Then I build again, and it worked.

PS: I tried everything before this like, changing the version no. of @ionic/native plugins to same version(4.3.3) but it didn’t work, then I tried to fulfil all the UNMET dependencies but it also didn’t work.

Try to update your package.json dependencies using https://update.ionic.zone/ and run the following:

rm -rf node_modules
npm install

I tried the Dirty work… :sweat_smile: It resolved the issue… It work… Finally made a prod build for first time :cowboy_hat_face: This was for my ionic 3 application which is 2 years old… Glad that it work… Thanks very much:cowboy_hat_face: