1.0.1 • Published 6 months ago

react-select-menu-valentindft v1.0.1

Weekly downloads
-
License
MIT
Repository
github
Last release
6 months ago

Select Menu

This is a component for an input list https://www.npmjs.com/package/react-select-menu-valentindft

Model

Prerequisites

This project requires NodeJS and NPM. Node and NPM are really easy to install. Make sure there are install in your device.

Installation

Install the npm package in your project

npm i react-select-menu-valentindft

How to use it

Import

import { SelectMenu } from 'react-select-menu-valentindft';

Component

// data is the data you want to list inside the input
// you can add an id to the input
// inputValue is the input value selected

<SelectMenu data={myData} id='some id' inputValue={valueSelectMenuMyData} />

Inject Data

// The structure of your data need to be an array of object with key name

const myData: Array<object> = [
   {
      name: 'First value'
   },
   {
      name: 'Second value'
   },
   {
      name: 'Third value'
   }
]

Model

Input value

let stateInput: string;

const valueSelectMenuMyData = (value: string) => {
    stateInput = value;
};
1.0.1

6 months ago

1.0.0

7 months ago

0.0.4

7 months ago

0.0.3

7 months ago

0.0.2

7 months ago