Quantcast
Channel: Ionic Framework - Ionic Forum
Viewing all articles
Browse latest Browse all 49308

@ionic-native/base64 and @ionic-native/file-picker are not working in Ionic 7 – How to fix?

$
0
0

Hi all,

I recently upgraded my project to Ionic 7, and I’m trying to use Base64 and IOSFilePicker. Previously, I was able to import them like this:

import { Base64 } from '@ionic-native/base64/ngx';
import { IOSFilePicker } from '@ionic-native/file-picker/ngx';

However, after the upgrade, I can no longer import these modules. I’ve read that @ionic-native/* plugins have been deprecated and replaced by @awesome-cordova-plugins/*, so I tried updating them:

Steps I took:

  1. Installed the new plugins:
npm install @awesome-cordova-plugins/base64
npm install @awesome-cordova-plugins/file-picker
  1. Added the necessary Cordova plugins:
ionic cordova plugin add cordova-plugin-file
ionic cordova plugin add cordova-plugin-filepicker
  1. Updated my app.module.ts to register the providers:
import { Base64 } from '@awesome-cordova-plugins/base64/ngx';
import { IOSFilePicker } from '@awesome-cordova-plugins/file-picker/ngx';

@NgModule({
  providers: [
    Base64,
    IOSFilePicker
  ]
})

The Problem:

  • When trying to import Base64 and IOSFilePicker, I get a “Module not found” error.
  • I also encountered an RxJS compatibility issue after upgrading.

@ionic/angular”: “^7.0.0”,
“rxjs”: “~7.8.0”,

1 post - 1 participant

Read full topic


Viewing all articles
Browse latest Browse all 49308

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>