github ankeetmaini/react-infinite-scroll-component v7.2.1
v7.2.1 - Accessibility props

5 hours ago

What's new

Accessibility props

You can now pass role, aria-label, aria-labelledby, tabIndex, id, and any aria-* attribute directly to the scroll container:

<InfiniteScroll
  role="list"
  aria-label="Search results"
  dataLength={items.length}
  next={fetchMore}
  hasMore={hasMore}
  loader={<p>Loading...</p>}
>
  {items.map(item => (
    <div role="listitem" key={item.id}>{item.name}</div>
  ))}
</InfiniteScroll>

Closes #411. Thanks to @sayedrisat for the contribution!

Commits

  • feat: add accessibility props to scroll container (#432)
  • docs: expand accessibility props table and add usage examples (#433)

Don't miss a new react-infinite-scroll-component release

NewReleases is sending notifications on new releases.