显示后端返回的图片(验证码)


在请求头中配置

responseType: "blob"

请求成功后

image.url = window.URL.createObjectURL(new Blob([res.data],{type:"image/jpeg"}))

posted @ 2023-03-28 10:57  我的世界蹦擦擦  Views(13)  Comments(0Edit  收藏  举报