react-native-autorecyclerlistview
TypeScript icon, indicating that this package has built-in type declarations

1.0.4 • Public • Published

react-native-autorecyclerlistview

AutoRecyclerListView inspired by recyclerListView and react-native-autoscroll-flatlist

Installation

# Using yarn

 yarn add react-native-autorecyclerlistview

# Using npm

 npm add react-native-autorecyclerlistview

Demo

Code provided in Example folder.

Usage

Simple usage

...
import AutoRecyclerListView, {ListAutoRenderItem} from 'react-native-autorecyclerlistview'

const Sample = () => {
  const [data, setData] = useState<string[]>([])

  useEffect(() => {
    setInterval(() => {
      setData((prev) => [...prev, 'Hello world!'])
    }, 1000)
  }, [])

  const _renderItem: ListAutoRenderItem<string> = ({ item, index }) => {
    return (
      <View style={{ flex: 1 }}>
        <Text children={item} />
      </View>
    )
  }

  return (
    <View>
      <AutoRecyclerListView data={data} renderItem={_renderItem} />
    </View>
  )
}

Props

Updating...

License

MIT

Readme

Keywords

none

Package Sidebar

Install

npm i react-native-autorecyclerlistview

Weekly Downloads

0

Version

1.0.4

License

MIT

Unpacked Size

19.7 kB

Total Files

12

Last publish

Collaborators

  • 1234569jqk