Rest API post method i was used in my app ionic serve working properly but when i was run to android i will not showing the result .If i am using
ionic cordova run android -l -c this livereload option it will be working only problem is when i was running in the android device it will not working how can i solve this issue…
any solution thanks …!
This is antipattern soup. You do not need to be creating headers. You do not need to be manually stringifying objects. You do not need to be setting content type. You should not be creating Promises. You should not be subscribing in the same place you are generating an Observable. You should be declaring types for all parameters and function return values.
I have same issue in Android, rest api not working in android emulator or device and give error: Response with 0 for Url: null.
But finally i got solution that there is cordova platform android version issue, if there is cordova Android version is 6.3 then it’s working properly but it there is cordova Android version is 7.0 or 7.1.1 then it’s not working for me.
You can check ios or android version using cli command. ionic info
Also check your all cordova plugins is installed or not. If someone is missing then install it manually and check again.
You can check your cordova plugins using cli command. cordova plugin -ls
I think it is helpful you.