@inwebo/assetsloader.js

0.0.2 • Public • Published

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);
    });

Package Sidebar

Install

npm i @inwebo/assetsloader.js

Weekly Downloads

2

Version

0.0.2

License

GPL-3.0

Unpacked Size

38.9 kB

Total Files

7

Last publish

Collaborators

  • inwebo