📜  传递参数 axios 得到反应 - Javascript 代码示例

📅  最后修改于: 2022-03-11 15:02:14.292000             🧑  作者: Mango

代码示例1
const params = new URLSearchParams([['answer', 42]]);

const res = await axios.get('https://httpbin.org/get', { params });
res.data.args; // { answer: 42 }