Lazy-loading the main part of the app (#197)

* Splitting main part of app out of the main bundle.

Also improving the transition from intro to compressor.

* Showing error if app fails to load.

* lol these aren't async

* Please don't tell anyone I did this

* Spinner if user selects a file before the app has loaded. (#208)
This commit is contained in:
Jake Archibald
2018-10-20 12:53:36 +01:00
committed by GitHub
parent a79f95b305
commit e24d7865ce
20 changed files with 604 additions and 464 deletions

View File

@@ -272,10 +272,7 @@ export default class PinchZoom extends HTMLElement {
private _stageElChange() {
this._positioningEl = undefined;
if (this.children.length === 0) {
console.warn('There should be at least one child in <pinch-zoom>.');
return;
}
if (this.children.length === 0) return;
this._positioningEl = this.children[0];