1.4.34 • Published 4 years ago

plurall-infinite-list v1.4.34

Weekly downloads
-
License
MIT
Repository
-
Last release
4 years ago

PlurallInfiniteList

This component encapsulates the infinite scroll list used in many of our applications.

How to use

There are four required props:

  • endpoint: the url you want to fetch
  • accessToken: the api access token
  • renderItem: a render function that will be called for each item the api returns
  • renderLoadButton: a render function for the load more button. This function receives the components props as the first parameter.

Example:

<InfiniteListContainer
  endpoint="InfiniteListContainer"
  accessToken="123"
  renderItem={post => <div>{post.title}</div>}
  renderLoadButton={props => <button>Load {props.pageSize} More</button>}
>

Optional props

  • renderLoading: a render function for the 'loading' placeholder that will be shown as the api request is made.
  • apiPageNumberParameterName: the name of the parameter the api uses to indicate the page to be fetched.
  • apiPageSizeParameterName: the name of the parameter the api uses to indicate the number of results per page.
  • pageSize: the number of results per page.
  • keyName: the item property to be used as key on the list.
1.4.34

4 years ago

1.4.33

5 years ago

1.4.32

6 years ago

1.4.31

6 years ago

1.4.30

6 years ago

1.4.29

6 years ago

1.4.28

7 years ago

1.4.27

7 years ago

1.4.26

7 years ago

1.4.25

7 years ago

1.4.24

7 years ago

1.4.23

7 years ago

1.4.22

7 years ago

1.4.21

7 years ago

1.4.20

7 years ago

1.4.19

7 years ago

1.4.18

7 years ago

1.4.17

7 years ago

1.4.16

7 years ago

1.4.15

7 years ago

1.4.14

7 years ago

1.4.13

7 years ago

1.4.12

7 years ago

1.4.11

7 years ago

1.4.10

7 years ago

1.4.9

7 years ago

1.4.8

7 years ago

1.4.7

7 years ago

1.4.6

7 years ago

1.4.5

7 years ago

1.4.4

7 years ago

1.4.3

7 years ago

1.4.2

7 years ago

1.4.1

7 years ago

1.4.0

7 years ago

1.3.9

7 years ago

1.3.8

7 years ago

1.3.5

7 years ago

1.3.4

7 years ago

1.3.3

7 years ago

1.3.2

7 years ago

1.0.15

7 years ago

1.0.12

7 years ago

1.0.10

7 years ago

1.0.7

7 years ago

1.0.4

7 years ago

1.0.1

7 years ago