Storybook Tests: only the first code excerpt is loaded in search results #16095
Labels
bug
An error, flaw or fault that produces an incorrect or unexpected result, or behavior.
team/code-search
Issues owned by the code search team
testing
Issues that deal with unit tests, integration tests and the testing infrastructure.
Projects
In storybook tests which show search results (both for GraphQL and streaming search), only the first code excerpt is loading:
After debugging, I found out that the code excerpt thinks it's not visible. The library we are using to determine visibility is react-visibility-sensor, which looks like it's dead: joshwnj/react-visibility-sensor#179
We should consider switching to a newer library that uses InsersectionObserver instead, such as this one: https://github.com/thebuilder/react-intersection-observer
Note that this does not happen in the actual web app, only in storybook tests.
The text was updated successfully, but these errors were encountered: