trigger.io hangs on splash screen in iOS

試著忘記壹切 提交于 2020-01-03 17:11:18

问题


Oftentimes my app will hang on the "trigger.io FORGE" splash screen and never display my UI.

I have this happening both in the simulator and on a real device. It's intermittent which leads me to think maybe it's a race condition somewhere (do I need to be waiting for forge to initialize?).

I have no idea how to debug this as the trigger console isn't spitting out an error even when showing the debug output.

Anything I should check? It's weird because if I put in a call like this:

setInterval(function() {
    forge.logging.log('hi');
}, 1000);`

I can see that my JavaScript code is being executed (and continues to execute as this is successfully logged until I kill the app).. but it's still hung on the splash screen. Oftentimes hitting the home button and re-entering the app will work. But sometimes it takes a few rebuilds before it will get past the splash screen.

I've now seen this on 2 different dev environments, 2 different physical devices, and the iOS simulator.


回答1:


This sounds like a rare issue on iOS that causes the DOM event Forge listens for to hide the splash screen not to fire.

The easiest way to fix this is to make sure the splash screen is hidden by calling forge.launchimage.hide() at the point your code is ready. See http://docs.trigger.io/en/v1.4/modules/launchimage.html#hide for more details.

If that doesn't help then let us know and we can try to track down what else it could be.



来源:https://stackoverflow.com/questions/13593928/trigger-io-hangs-on-splash-screen-in-ios

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!