Get width height of remote image from url
Get image size with JavaScript In order to read the data from an image you’ll need to make sure it’s first loaded. Here’s a callback-based approach and two promise-based solutions: Callback const getMeta = (url, cb) => { const img = new Image(); img.onload = () => cb(null, img); img.onerror = (err) => cb(err); img.src … Read more