React native pagination dots.
npm i react-native-pagination-dots
import React from 'react'
import PaginationDots from 'react-native-pagination-dots'
export default App() => {
const length = 5
const index = 2
return (
<PaginationDots length={length} activeIndex={index} />
)
}
Property | Type | Default | Description |
---|---|---|---|
length | number | 5 | Total number of dots |
activeIndex | number | 0 | Index of active dot |
activeWidth | number | 30 | Width of active dot |
passiveWidth | number | 10 | Width of non-active dot |
height | number | 10 | Height of dots |
spacing | number | 5 | Spacing between dots |
activeColor | string | "#ffffff" |
Color of active dot |
passiveColor | string | "#ffffff" |
Color of non-active dot |