0.0.4 • Published 4 years ago

@mateuszmigas/dropdown v0.0.4

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

React dropdown

This project does not try to implement the ultimate dropdown that will solve all the problems because it's not possible. It provides a set of utilities for creating such dropdown with examples showing how to do so.

Examples

Features

  • controlled vs uncontrolled state - useDropdownState hook allows you to decide which part of the state you want to control. Check DropdownSimple vs DropdownControlledState
  • redux-like state management - it exposes predefined actions and reducer. Both can be changed/extended
  • VirtualizedList - a component that uses react-window with item memoization that will render only what's needed and reuse already rendered items
  • VirtualizedLazyLoadingList - covers all the functionality of VirtualizedList but allows for lazy loading chunks of items. Uses: react-window-infinite-loader
  • Customizable:
    • keyboard navigation
    • mouse navigation
    • focus management

Installation

npm i @mateuszmigas/dropdown

or

yarn add @mateuszmigas/dropdown

Check examples for the usage

Development

dropdown / yarn;
dropdown / examples / yarn;
dropdown/yarn run watch
dropdown/examples/yarn start

Work in progress

  • Check tree-shaking
  • Profile

License

MIT

0.0.4

4 years ago

0.0.3

4 years ago

0.0.2

4 years ago

0.0.1

4 years ago