https://googlechrome.github.io/samples/intersectionobserver/
I have found that the line 'if (entries.some(entry => entry.intersectionRatio > 0)) {' can cause some issues.
The issue is that it is possible to get entry.intersectionRatio to be equal to 0 (zero), so it would fail and not add extra content.
I have changed the comparison to entry.intersectionRatio >= 0 , That seems to be okay. The intersectionRatio even if zero is having the target element appear/disappear from the root element (by what I've read, even 1px causes the intersection).
https://googlechrome.github.io/samples/intersectionobserver/ I have found that the line 'if (entries.some(entry => entry.intersectionRatio > 0)) {' can cause some issues. The issue is that it is possible to get entry.intersectionRatio to be equal to 0 (zero), so it would fail and not add extra content. I have changed the comparison to entry.intersectionRatio >= 0 , That seems to be okay. The intersectionRatio even if zero is having the target element appear/disappear from the root element (by what I've read, even 1px causes the intersection).