document.readyState is not changing in Chrome and Mozilla but changes in IE

674 Views Asked by At

document.readyState is able to track values such as 'complete' ,'interactive' in IE. but in Chrome document.readyState is getting set to 'complete' and no 'interactive' state is tracked.

As the state is not getting changed from 'complete' document.onreadystatechange is not getting triggered.

document.onreadystatechange = function () {
  if (document.readyState === "interactive") {
    ReleaseSpinner(my Custom code);
  }
}
0

There are 0 best solutions below