riku
2026-04-02 3282e95db0207ee133d1e98d9771dec9d83b0fc4
1
2
3
4
5
6
7
function shouldLoadImage(index, currentIndex, loadedIndexes) {
  return Math.abs(index - currentIndex) <= 1 || (loadedIndexes && loadedIndexes.indexOf(index) !== -1);
}
 
module.exports = {
  shouldLoadImage: shouldLoadImage,
};