0.0.2 • Published 4 years ago

@inwebo/assetsloader.js v0.0.2

Weekly downloads
1
License
GPL-3.0
Repository
github
Last release
4 years ago

AssetsLoader.js

Asynchronously Load assets in the Browser with promises.

Install

Npm

npm i @inwebo/assetsloader.js

Yarn

yarn i @inwebo/assetsloader.js

Git

git clone https://github.com/inwebo/AssetsLoader.js.git

Use

import {AssetsLoader} from '@inwebo/assetsloader.js'

const img = AssetsLoader.image('https://raw.githubusercontent.com/inwebo/Sprite.js/master/docs/assets/img/mario.png');

Promise.all([img])
    .then(([img]) => {
        // img const is available
        console.log(img);
    });