New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

react-multi-level-selector

Package Overview
Dependencies
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-multi-level-selector

Multi level dropdown options selector for application

  • 1.0.1
  • latest
  • Source
  • npm
  • Socket score

Version published
Maintainers
1
Created
Source

react-multi-level-selector

:bell: React component for Multi level options Selector for your application.

Installation

Install it from npm and import it in your root component

npm install --save react-multi-level-selector

Usage

import React from 'react';
import MultiLevelSelect from 'react-multi-level-selector';

const options = [
  { value: 'fruits', label: 'Fruits',
    options: [
      { value: 'citrus', label: 'Citrus',
        options: [
          { value: 'orange', label: 'Orange' },
          { value: 'grapefruits', label: 'GrapeFruits'},
        ],
      },
      { value: 'tropical', label: 'Tropical',
        options: [
          { value: 'mango', label: 'Mango' },
          { value: 'papaya', label: 'Papaya' },
        ],
      },
      { value: 'berries', label: 'Berries',
        options: [
          { value: 'strawberry', label: 'Strawberry' },
          { value: 'raspberries', label: 'Raspberries' },
        ],
      },
    ],
  },
  { value: 'city', label: 'City',
    options: [
      { value: 'dublin', label: 'Dublin' },
      { value: 'new york', label: 'New York' },
      { value: 'san fransis', label: 'San Fransis' },
    ],
  },

function App() {
  return (
    <div>
      <MultiLevelSelect
        options={options}
      />
      <div>This is a test application</div>
    </div>
  )
}

export default App;

Props

NameTypeDescription
options{Array}Options for the dropdown. Specify the options for users to select from.
placeholder{String}The text displayed when no option is selected.
onChange{function}Subscribe to change events.
className{String}className to style the selector

Keywords

FAQs

Package last updated on 07 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

SocketSocket SOC 2 Logo

Product

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

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc