Typeahead是一款基于Bootstrap框架的自动补全插件,插件用来完成输入框的自动完成、模糊搜索和建议提示的功能,同时支持bootstrap3和Bootstrap4。
绑定数据源
$(".typeahead").typeahead({ source: [ {id: "id1", name: "jQuery"}, {id: "id2", name: "Script"}, {id: "id3", name: "Net"}, {id: "id4", name: "javascript"}, {id: "id5", name: "java"}, {id: "id6", name: "Php"}, {id: "id7", name: ".Net"}, ] });或者直接读取json文件
$.get("data.json", function(data){ $(".typeahead").typeahead({ source:data }); },'json');
Bootstrap搜索结果无刷新补全插件
正在加载文件目录...
- 热度 37
![](https://imgs.bootstrapmb.com/2024/4/060159326.jpg)
CAMELLIA下载了 此素材
![](https://imgs.bootstrapmb.com/2024/3/260855529.jpg)
:)下载了 此素材
![](https://imgs.bootstrapmb.com/2024/3/260855529.jpg)
:)下载了 此素材
![](https://imgs.bootstrapmb.com/2024/3/260855529.jpg)
:)收藏了 此素材
![](https://imgs.bootstrapmb.com/2022/3/120901598.jpg)
图风下载了 此素材
![](https://imgs.bootstrapmb.com/2023/8/070304067.jpg)
Thorn、下载了 此素材
![](https://imgs.bootstrapmb.com/2023/10/120453479.jpg)
拾柒下载了 此素材
![](https://imgs.bootstrapmb.com/2021/8/230317596.jpg)
润宇下载了 此素材
![](https://imgs.bootstrapmb.com/2020/3/111101233.jpg)
北极不熊下载了 此素材
![](https://imgs.bootstrapmb.com/2022/12/030227483.jpg)
ily下载了 此素材