Socket
Socket
Sign inDemoInstall

react-large-datalist

Package Overview
Dependencies
8
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    react-large-datalist

Dropdown element for large data set


Version published
Maintainers
1
Created

Readme

Source

React large data list

React drop down for large data items.

Why this component?

  • This is designed for the purpose of handling large number of dropdown items.
  • Most of the popular React dropdown libraries slow down massively when the dataset has more than 1000 items. This component can handle any large data set without any significant slowness.

Props

  • options : array, Array of elements.
  • onChange : function(value)
  • containerStyle : object, Style for main container.
  • inputContainerStyle : object, Style for main container.
  • inputStyle : object, Input text box style.
  • disabled : boolean, true/false
  • clearIconStyle : object, Clear textbox icon style
  • createButtonStyle : object, Create option style
  • onClickCreate : function (value), called when user clicks on create button,
  • defaultValue : string, Initial value

Install

npm i react-large-datalist

Code

...
import ReactLargeDatalist from 'react-large-datalist';
...
...
<ReactLargeDatalist
   options={["Option 1", "Option 2", "Option 3"]}
   disabled={false}
   defaultValue="Option 2"
   onChange={(value) => {console.log("Selected value:", value)}}
   onCreate={(newValue)=>{console.log("Created value", newValue)}}
/>
...
...

Demo link

GitHub link

Keywords

FAQs

Last updated on 25 Jun 2019

Did you know?

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

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc