New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

scrollify-list

Package Overview
Dependencies
Maintainers
1
Versions
8
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

scrollify-list

Super easy client-side infinite scroll for React.

latest
Source
npmnpm
Version
0.6.1
Version published
Maintainers
1
Created
Source

scrollify-list

Super easy client-side infinite scroll for React.

Handy in a situation where you are needed to render a big chunk of data.

Usage

Install:

npm install --save scrollify-list

How to use (basic example):

import React from 'react'
import ReactDOM from 'react-dom'
import ScrollifyList from 'scrollify-list'

const generateData = () =>
  Array(500)
    .fill(null)
    .map(() => ({
      id: Math.random()
        .toString(36)
        .substring(7),
      name: Math.random()
        .toString(36)
        .substring(7),
    }))

const App = () => (
  <ScrollifyList
    data={generateData()}
    render={data => <h1 key={data.id}>{data.name}</h1>}
  />
)

ReactDOM.render(<App />, document.getElementById('example'))

Configure

PropertyExplanation
dataYour data! Array of something.
renderHow do you want to render your data?
pageSizeHow many rows in one page? Defaults to 15.

Develop

  • npm run dev
  • cd examples/basic/ && npm install && npm run start
  • Go to http://localhost:1234/
  • Make changes to /src/index.js
  • ???
  • Profit! 😎✌️

Keywords

list

FAQs

Package last updated on 24 Nov 2019

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts