errors in ionic3 project

Using "requireCordovaModule" to load non-cordova module "glob" is not supported. Instead, add this module to your dependencies and use regular "require" to load it.

answer:


Solved this problem by installing a lower version of cordova. Seems like every version of cordova that is > 8.1.1 breaks a number of plugins.
For instance, the plugin cordova-sqlite-storage failed to install with the following error message:
Failed to install 'cordova-sqlite-storage': CordovaError: Using "requireCordovaModule" to load non-cordova module "q" is not supported. Instead, add this module to your dependencies and use regular "require" to load it.
To solve that issue, I simply removed cordova by calling npm uninstall cordova -g and then installed it globally again with npm install -g cordova@8.1.1
After that fix, no more errors are getting displayed and cordova-sqlite-storage gets installed smoothly!!
Installing "cordova-sqlite-storage" for android

Failed to install the following Android SDK packages as some licences have not been accepted.

yes | $ANDROID_HOME/tools/bin/sdkmanager "build-tools;28.0.3"

https://stackoverflow.com/questions/48725618/ionic-3-execution-failed-for-task-appprocessdebugresources

Execution failed for task ':app:compileDebugJavaWithJavac

home/nss/bhavanieverestandroid/CarCare_26-02send/platforms/android/app/src/main/java/com/synconset/ImageFetcher.java:293: error: Entry is not public in LinkedHashMap; cannot be accessed from outside package

        protected boolean removeEldestEntry(LinkedHashMap.Entry<Integer, Bitmap> eldest) {
                                                         ^
Note: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
Note: Some input files use unchecked or unsafe operations.
Note: Recompile with -Xlint:unchecked for details.

answer:

protected boolean removeEldestEntry(LinkedHashMap.Entry<Integer, Bitmap> eldest) {
replace line with
protected boolean removeEldestEntry(HashMap.Entry<Integer, Bitmap> eldest) {

Comments

Popular posts from this blog

How to Add Firebase Analytics to Your NativeScript Mobile App

sidemenu refresh through events

push multiple data in array(select and disselect items in array)