1.0.4 • Published 5 years ago

react-auto-search v1.0.4

Weekly downloads
1
License
MIT
Repository
-
Last release
5 years ago

react-auto-search

Keyword search component for react js

NPM JavaScript Style Guide

Install

npm install --save react-auto-search

Usage

import React, { Component } from 'react'
import axios from 'axios'
import AutoSearch from 'react-auto-search'

const instance = axios.create({
    baseURL: '',    /* API BASE URL */
    headers: {
        /* AUTHENTICATION TOKEN */
    }
})

class Example extends Component {
  render () {
    return (
      <AutoSearch 
          selectedItems = {[]}
          url = {""}    /* /path/queryString/path */
          onSelectedItemChanged = {(items) => {console.log("SELECTED ITEM ::: ",items)}}
          isMultiple = {true}
          axiosInstance = {instance}
          idColumnKey="id"    
          valueColumnKey="serialNumber"
          responseListSize={10}
          placeholder="Type something to search locks..."
          activeListItemColor="#f4b342"
          selectedListItemColor="#41f4f4"
          isShowRemoveIcon={false}
      />
    )
  }
}

License

MIT © Narenthera prasanth(https://github.com/Narenthera prasanth)

1.0.4

5 years ago

1.0.3

5 years ago

1.0.2

5 years ago

1.0.1

5 years ago

1.0.0

5 years ago

0.1.4

5 years ago

0.1.3

5 years ago

0.1.2

5 years ago

0.1.1

5 years ago

0.1.0

5 years ago