try this,
ionic start new_project --v2
- in new_project dir,
ionic plugin add cordova-plugin-file
-
declare let cordova:any;
below import in your home.ts - then add this in your HomePage class constructor:
console.log(cordova.file.dataDirectory); //make app stuck in white screen forever.
-
ionic run ios
(in my case iOS simulator runs) (‘ionic platform add ios’ if not there)
I did nothing special. I have no problem on android. but why is it crashing ionic app?