Skip to content

Commit

Permalink
Minor renaming and clean up (#24)
Browse files Browse the repository at this point in the history
  • Loading branch information
mjbp authored May 7, 2019
1 parent 863aa9c commit 46fab84
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions src/js/app.js
Original file line number Diff line number Diff line change
@@ -1,14 +1,12 @@
import { PATHS } from './constants';
import Promise from 'promise-polyfill';
import Load from 'storm-load';
const r = f => f();
const onInit = [];
const initStack = [];

{
window.Promise = window.Promise ? window.Promise : Promise;
document.documentElement.className = document.documentElement.className.split('no-js').join('');

if (!Object.assign) {
Load(`${PATHS.JS_ASYNC}/polyfills.min.js`).then(() => onInit.map(r));
} else onInit.map(r);
if (!Object.assign) Load(`${PATHS.JS_ASYNC}/polyfills.min.js`).then(() => initStack.map(fn => fn()));
else initStack.map(fn => fn());
}

0 comments on commit 46fab84

Please sign in to comment.