I have an API which returns an Image as byte data, but I don't know how can I show this bytes in the src of the img tag
here is an example of what I got in the result
and this is how I use axios to make use of the API
const getFile = async (nombreArchivo) => {
const tokenApp = window.localStorage.getItem('token')
const {data: res} = await axios.get(`${url}photo-2.jpg`,
{ headers: { Authorization: `${tokenApp}` },responseType: 'json',});
return res;};