Sencha 2.4.2 cordova app stuck at "Device Ready" Screen on device

377 Views Asked by At

I am new to sencha and creating a app which is coming up on browser but not device. I have followed basic steps as mentioned in tutorial : https://docs.sencha.com/touch/2.4/getting_started/building_your_first_app.html

To simulate the case, here are the steps we executed:

  • sencha -sdk generate app MyApp

  • sencha cordova init com.mycompany.MyApp MyApp

  • sencha web start (with this we are able to run in browser)

  • Updated app.json to include android:

    "builds": {
      "web": {"default": true},
        "android": {
        "packager": "cordova",
        "cordova" : {                
              "config": {       
                "platforms": "android",
                "id": "com.mycompany.MyApp",
                "name": "MyApp"
            }
        }
    }
    },
    
  • sencha app build android

  • sencha app build -run android
  • Post this we were able to open app in android studio from cordova/platforms/android
  • when we executed from studio, it is always stuck at "Apache Cordova- Device is ready " screen .. which is from the html of MyApp/cordova/platforms/android/assets/www/index.html and it is not referring to /MyApp/index.html

Its same behaviour on iOS as well!!

Are we missing out any steps here ?

1

There are 1 best solutions below

0
On

You app.json was not structured properly. Edit your app.json to reflect below and run sencha app build.

"builds": {
    "native": {
        "default": true,
        "packager": "cordova",
        "cordova" : {                
            "config": {       
                "platforms": "android",
                "id": "com.mycompany.MyApp",
                "name": "MyApp"
            }
        }
    }
},