Open Jos512 opened 5 years ago
Hmm. This tracks down to the very first commit:
Back then ga-lite had functionality of sending the pageviews on window.onunload
, and since Internet Explorer doesn't support navigator.sendBeacon
, there was a fallback to use XMLHttpRequest
. The gist here is that IE needed to use synchronous requests to guarantee taht those requests were finished on the unload
event.
This means we can safely remove the synchronous flag from the XMLHttpRequest
call.
Source and further explanation for the synchronous flag:
If I perform a Google mobile friendly test on a website that uses
ga-lite
, I get the following error message:Here's an example of such a mobile friendliness report.
The problem looks to be caused by this line.