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

multiselection-input

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

multiselection-input

make multiple selection in the selectbox

latest
Source
npmnpm
Version
1.1.1
Version published
Maintainers
1
Created
Source

multiselection-input

make multiple selection in the selectbox

NPM JavaScript Style Guide

Install

npm install --save multiselection-input

Usage

import React, { Component } from 'react'

import Multiselection from 'multiselection'
import 'multiselection/dist/index.css'

class Example extends Component {
  state = {
    text: ["Create 😄", "React 😄", "Library 😄", "Example 😄"],
    result: []
  }
  handleValue = (result) => {
    this.setState({result})
  }
  render() {
    const {text, retour} = this.state;
    return (
    <>
      <Multiselection
        width={400}
        data={text}
        handleValue={this.handleValue}
        border={'solid 2px red'} 
        margin={'15%'}
      />
      <ul>
         <h4>Selected element</h4>
             {result.map(item => 
                <li key={item}>{item}</li>
             )}
      </ul>
    </>
  }
}

data : is a mandatory prop typeof list of string

handleValue : is a mandatory prop typeof func for retrieving the result of the select

width : is a optional prop typeof number border : is a optional prop typeof string for border style margin : is a optional prop typeof string for margin of the select

License

MIT © elsamanang

FAQs

Package last updated on 10 Apr 2022

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