question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

bug: cordova-plugin-ionic is blocking device ready event

See original GitHub issue

Bug Report

I am migrating our app from cordova to capacitor. Generally we managed to limit the cordova plugins to 3:

    cordova-plugin-ionic (5.4.4)
    cordova-plugin-whitelist (1.3.4)
    phonegap-plugin-barcodescanner (8.1.0)

Using cordova-plugin-ionic (5.4.4) is messing up deviceready event and app cannot be started.

When inspecting the app in Google remote devices the following error is shown. Uncaught (in promise) String resource ID #0x0. Similar issue should have been resolved in the plugin repo https://github.com/ionic-team/cordova-plugin-ionic/issues/223.

Once the plugin is removed the app start functioning as normal.

Capacitor Version

npx cap doctor output: 💊 Capacitor Doctor 💊

Latest Dependencies:

@capacitor/cli: 1.2.1

@capacitor/core: 1.2.1

@capacitor/android: 1.2.1

@capacitor/ios: 1.2.1

Installed Dependencies:

@capacitor/cli 1.2.1

@capacitor/core 1.2.1

@capacitor/ios 1.2.1

@capacitor/android 1.2.1

Affected Platform(s)

  • Android
  • iOS
  • Electron
  • Web

Current Behavior

Application cannot be roaded.

Expected Behavior

Application should be launched ans normal. No incompatible plugins are being used.

Sample Code or Sample Application Repo

Reproduction Steps

Inside an capacitor project run in terminal:

cordova plugin add cordova-plugin-ionic --save --variable APP_ID="abcd1234" --variable CHANNEL_NAME="Master" --variable UPDATE_METHOD="background"

ionic build or npm run build

npx cap sync android

npx cap open android

Run app in simulator or on device. App is not loaded correctly.

Other Technical Details

npm --version output: 6.9.0 node --version output: v10.16.3

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:6 (2 by maintainers)

github_iconTop GitHub Comments

5reactions
maximnaracommented, Jul 5, 2021

I’ve just remove old plugin cordova-plugin-ionic and problem gone

0reactions
ionitron-bot[bot]commented, Nov 11, 2022

Thanks for the issue! This issue is being locked to prevent comments that are not relevant to the original issue. If this is still an issue with the latest version of Capacitor, please create a new issue and ensure the template is fully filled out.

Read more comments on GitHub >

github_iconTop Results From Across the Web

cordova plugin is not ready - Stack Overflow
I have tried to bootstrap my app in 'deviceready' event. Still don't work. Please help me! Thanks! The index.html file: <body ...
Read more >
Deviceready did not fire - ionic-v3
Hi, when building for iOS i see the following in my logs: [12:37:49] console.log: Angular is running in the development mode.
Read more >
Ionic and Cordova's DeviceReady - My Solution
The Problem. The ionicPlatform. ready event is called when Cordova's deviceready event fires. When run on a desktop, it is fired when on...
Read more >
cordova-plugin-device
This plugin defines a global device object, which describes the device's hardware and software. Although the object is in the global scope, it...
Read more >
@iotize/device-com-wifi.cordova - npm
IoTize Cordova plugin for Wifi devices. ... after deviceready has been fired, see Cordova deviceready Event Docs ... Ionic/Angular Notes.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found