学无先后,达者为师

网站首页 编程语言 正文

图片返回base64数据渲染为图片的处理

作者:RAY_CHEN. 更新时间: 2022-02-23 编程语言

后端返回的图片路径为base64

前端渲染时,

this.codeUrl = "data:image/gif;base64," + res.img;

前面加data:image/gif;base64即可;

原文链接:https://blog.csdn.net/weixin_44707050/article/details/123110830

栏目分类
最近更新