2019年3月22日
摘要: 背景:项目前端ajax请求很多都没有写error方法,所以用户体验很不好 新来的前端负责人发现这个问题,写了一个错误处理方法,如下 1 //统一处理Ajax错误方法 2 function onAjaxError(xhr, textStatus, error) { 3 if (xhr.status = 阅读全文
posted @ 2019-03-22 22:46 cigarlau 阅读(771) 评论(0) 推荐(1)