https://github.com/algolia/places <!DOCTYPE html> <html lang="zh-CN"> <head> <meta charset="UTF-8"> <title>地址自动补充</title> </head> <body> <input type="search" id="address-input" placeholder="Where are we going?" /> </body> <script src="https://cdn.jsdelivr.net/places.js/1/places.min.js"></script> <script type="text/javascript"> var placesAutocomplete = places({ container: document.querySelector('#address-input') }); </script> </html> 提示:你可以先修改部分代码再运行。 转载请注明:有爱前端 » 地址自动补充 喜欢 (0)or分享 (0)