A React Autocomplete Component for Input
yarn add preact-autocomplete
or
npm install preact-autocomplete --save
- Filter data of object or array
- Customize filter value
- Customize output value
- Keyboard control
- Auto reset value (option)
- onChange callback
- Customize empty message
- Dropdown mode
yarn install
or
npm install
local development :
start a local development withyarn w
server onlocalhost:8080
local build :
yarn build
output to/lib/*
Demo deploy :
yarn p
output topublic/*
local test :
yarn test
一個使用於 autocomplete 或 dropdown 需求的 React component
yarn add preact-autocomplete
- 過濾物件、陣列
- 過濾任意key 值
- 帶出任意key 值
- keyboard 選擇
- 自動清空 (可選)
- 自訂選值後callback
- 自訂查無項目訊息
- 下拉選單模式
yarn install
本機開發 :
yarn w
預設於localhost:8080
開啟Hot Module Replacement
本機部署 :
yarn build
預設透過babel 放置於/lib/*
下
Demo部署 :
yarn p
預設產出至public/*
本機測試 :
yarn test