async、await ES7优化ES6异步编程的解决方案
文章目录
async、await ES7优化ES6异步编程的解决方案;
export function:
`
export async function loginM(username, password) {
var res1 = await API.post({
});
console.log(res1)
if (res1.code === 200) {
}
var res2 = await API.post({
});
console.log(res2)
if (res2.code === 200) {
}
console.log(2)
}
`
VUE中应用。

评论
登录后参与技术讨论,分享你的经验与见解。
登录 / 注册暂无评论