Live
react-stateless-infinite-scroll
The best react infinite scroll component, on earth 🌍
Usage
Install
npm install -S react-stateless-infinite-scroll
How to
import React from 'react'import InfiniteScroll from 'react-stateless-infinite-scroll' const Component = props const infiniteActions = loadMore const infiniteState = hasMore loading error const infiniteCustoms = spinner: <CustomSpinner /> reloader: <CustomReloader /> const infiniteOptions = threshold: 100 const infiniteStyle = height: 300 return <InfiniteScroll = = = = = > items </InfiniteScroll>
PropTypes
InfiniteScrollpropTypes = children: ReactPropTypesnode style: ReactPropTypes options: ReactPropTypes actions: ReactPropTypesisRequired state: ReactPropTypesisRequired customs: ReactPropTypes