img-load
Load an image for the browser from a given path
install
npm install img-loadusage
const load = require('img-load')
load('images/foo.png', (error, image) => {
if (error) throw error
document.body.appendChild(image)
})
image = load(path, callback)
Creates an HTMLImageElement instance using the given path, and executes callback upon completion.