1.4.9 • Published 6 years ago
react-city-input v1.4.9
react-city-input
install
npm install react-city-input
user
import City from 'react-city-input';
render() {
return(
<City
onChange={(value)=>{
console.log(value)
}}
value={'北京'}
disabled={false}
readonly={false}
/>
)
}
说明
pc端city,模仿携程,数据是 lib/Data.js
含有热点城市,按字母进行查找
包含选择乘车
匹配查找城市
主要针对中国主要城市
example
- git clone git@github.com:tongchuan/react-city-input.git
- npm install or yarn
- npm run dev
- npm build
- npm release
- npm run dev ===> http://127.0.0.1:8080
- 可以修改lib下的Data数据
- 可以修改lib源代码
- 整个工程是全的,可以任意修改