englercj / resource-loader

A middleware-style generic resource loader built with web games in mind.
http://englercj.github.io/resource-loader/
MIT License
424 stars 77 forks source link

Improper ES6 imports #123

Closed goldenratio closed 5 years ago

goldenratio commented 5 years ago

Hi,

in version 2.2.1, we are getting undefined errors.

screen shot 2018-12-14 at 14 21 35

On further investigation, in blob.js Resource class imported as default, but Resource class is not exported as default. (Same for encodeBinary)

import Resource from '../../Resource';
import b64 from '../../b64';

should be,

import { Resource } from '../../Resource';
import { encodeBinary } from '../../b64';

screen shot 2018-12-14 at 14 21 49

Note: version 2.2.1, is automatically picked up NPM, all new builds are broken.

shako92 commented 5 years ago

Same here, pixi stopped working:

image

And error in console:

image

All builds are broken.

englercj commented 5 years ago

Sorry about this, should be fixed in v2.2.2 now. Let me know if it isn't.