Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

React/redux app renders blank screen on Safari

I built an app in React/redux that works in every browser I tried, BUT Safari on MacOS and any browser on iPhone. I get no error, no console message, nothing that would give me some idea. It only renders tag in Safari and the screen is blank.

http://podcast.exploration.io

Do you have any idea how could I trace this issue?

Thanks

like image 351
Michal Holub Avatar asked May 09 '16 12:05

Michal Holub


People also ask

Why is my React app showing blank screen?

A blank or white screen occurs when React encounters a rendering error in a component (for example, trying to render obj. param when obj is undefined).

Does React work on Safari?

React 18 supports all modern browsers (Edge, Firefox, Chrome, Safari, etc).

Why is React not displaying anything?

check your console for errors chances are high it's not showing any and if it does , try to trace the back to the line of bug that was thrown and fix it. There's probably an infinite loop running somewhere in your code.

Why is my React production app not working on mobile browsers?

There is likely an uncaught error that is occurring that is causing React to go to a blank screen. This could be because your mobile client is having difficulty reaching the API and the call is failing.


1 Answers

I found the issue. The main reason why it failed was 'fetch' function...which is not available in Safari. I'm not sure why it wouldn't print anything, but I suspect, because 'fetch' was called inside try/catch.

like image 175
Michal Holub Avatar answered Sep 17 '22 16:09

Michal Holub