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

react-autosuggestive

Package Overview
Dependencies
Maintainers
1
Versions
9
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-autosuggestive

Autosuggest react widget

latest
Source
npmnpm
Version
1.0.8
Version published
Maintainers
1
Created
Source

react-autosuggest

Imitating native html5 autocomplete with react

Installation

git clone https://github.com/DarekPobozniak/react-autosuggest.git
cd react-autosuggest
npm install

Start

npm start

Installation

npm install react-autosuggestive --save

Basic Usage

import Autosuggest from 'react-autosuggestive';

// Basic list of names
const names = ['Anna', 'John', 'Darek', 'David'];

<Autosuggest
  datalist={names}
/>

// Basic list of names with selected default value
<Autosuggest
  datalist={names}
  currentValue="Darek"
/>

// List of countries with codes
const countries = [
  { name: 'Poland', code: 'PL' },
  { name: 'Germany', code: 'DE' },
  { name: 'Czech Republic', code: 'CZ' },
];

<Autosuggest
  datalist={countries}
  label="name"
  value="code"
  currentValue="CZ"
/>

// List of localized county names with codes
const localizedCountries = [
  {
    name: {
      en_gb: 'Poland',
      pl: 'Polska',
    },
    code: 'PL',
  },
  {
    name: {
      en_gb: 'Germany',
      pl: 'Niemcy',
    },
    code: 'DE',
  },
  {
    name: {
      en_gb: 'Czech Republic',
      pl: 'Czechy',
    },
    code: 'CZ',
  },
];

<Autosuggest
  datalist={countries}
  label="name"
  value="code"
  currentValue="CZ"
  labelKey="pl"
/>

Keywords

react

FAQs

Package last updated on 21 Oct 2016

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