1.1.0 • Published 2 years ago

react-library-senga v1.1.0

Weekly downloads
-
License
MIT
Repository
-
Last release
2 years ago

react-library-senga

A React library for creating custom Select components.

prerequisites

  • react
  • react-dom
  • npm

Repository

CodeSandbox

try it on CodeSandBox

installation

install with npm:

npm install react-library-senga

install with yarn:

yarn add react-library-senga

using options

You can pass an array of options to the options prop to define the possible choices in the dropdown menu. Each option should have a value and a label. Here's an example:

import React from 'react';
//import the Select component 
import Select from 'react-library-senga';

function MySelect(){
  //customise your options
   const optionList = [
      {value: 'option1', label: 'Option 1'},
      {value: 'option2', label: 'Option 2'},
      {value: 'option3', label: 'Option 3'},
   ];

    return (
        <Select
        options={optionList}
        />
    );
}

export default MySelect;
1.1.0

2 years ago

1.0.9

2 years ago

1.0.8

2 years ago

1.0.7

2 years ago

1.0.6

2 years ago

1.0.5

2 years ago

1.0.4

2 years ago

1.0.3

2 years ago

1.0.2

2 years ago

1.0.1

2 years ago

1.0.0

2 years ago