I\'ve added material icons to ionic2 app , and since then I get error \"\"The connection to the server was unsuccessful. (file:///android_asset/www/index.html)\"\" although the
So I added manually the following tags in config.xml right at the beginning:
<allow-navigation href="*" />
<content src=“index.html” />
<content original-src=“index.html” />
it’s working.
Adding that ...value="70000" or "60000" line in config.xml isn't the best solution and it doesn't always work nor the creation of main.html file .
I was dealing with the same issue. These two solutions did not work for me.
SOLUTION
-Make sure you build with
ionic cordova build --prod and not ionic cordova build
-Check if one of your file or folder name doesn't contain Uppercase in it's context before building
like for example in "pages"
templateView (instead of "templateview)
and rename it (otherwise you will have errors)
When building finished, your app runs correctly without the "(file:///android_asset/www/index.html)" error.