react-composable-dropdown

1.0.4 • Public • Published

React Composable Dropdown

Fancier than your average <input> dropdown.

Features

  • Specify your own interior <li> item view.
  • Dropdown button and list items can be styled with CSS, unlike the standard HTML dropdown.

Installation

npm install --save react-composable-dropdown

Using It

  var React = require('react');
  var Dropdown = require('./../src/index');

  var items = [
    {
      text: 'Apple Pie',
      value: 'apple'
    },
    {
      text: 'Blueberry Pie',
      value: 'blueberry'
    },
    {
      text: 'Peach Cobbler',
      value: 'peach'
    }
  ];

  React.render(
    React.createElement(Dropdown, {items: items, 		defaultText: 'Pie Options'}),
    document.querySelector('.container')
  );

Example

See README in /example/

License

MIT

Versions

Current Tags

  • Version
    Downloads (Last 7 Days)
    • Tag
  • 1.0.4
    0
    • latest

Version History

  • Version
    Downloads (Last 7 Days)
    • Published
  • 1.0.4
    0
  • 1.0.2
    0
  • 1.0.1
    0
  • 1.0.0
    0

Package Sidebar

Install

npm i react-composable-dropdown

Weekly Downloads

0

Version

1.0.4

License

MIT

Last publish

Collaborators

  • sgrider