摘要: axios axios是什么 axios是一个基于PRominse的HTTP库,可以用在浏览器和node.js中 第三方Ajax库 http://www.axios-js.com/zh-cn/docs/ axios的基本用法 <!DOCTYPE html> <html> <head> <meta c 阅读全文
posted @ 2023-03-24 21:21 zj勇敢飞,xx永相随 阅读(19) 评论(0) 推荐(0) 编辑
摘要: 封装Ajax <!DOCTYPE html> <html> <head> <meta charset="utf-8"> <title>封装Ajax</title> </head> <body> <script type="module"> /* const url = 'https://www.im 阅读全文
posted @ 2023-03-24 15:06 zj勇敢飞,xx永相随 阅读(14) 评论(0) 推荐(0) 编辑
摘要: XHR 的事件 load事件 //1.load事件 //响应数据可用时触发 const url ='https://www.imooc.com/api/http/search/suggest?words=js'; const xhr = new XMLHttpRequest(); // xhr.on 阅读全文
posted @ 2023-03-24 09:48 zj勇敢飞,xx永相随 阅读(142) 评论(0) 推荐(0) 编辑