Ok, so this seems to be the problem. Definitively - http://stackoverflow.com/questions/31219005/firebase-requests-stalling-at-negotiation-phase-how-to-debug
It’s fixed if you uncomment cordova.js in index.html.
Now I wonder what are the consequences of uncommenting cordova.js?