- npm: Update devDeps

- Build: Switch to `terser` plugin with `uglify` plugin not
    supporting ES6+-capable minifier
- Linting (ESLint): Consistent curly spacing; follow new "standard"
This commit is contained in:
Brett Zamir
2018-09-07 08:18:37 +08:00
parent cad412fe6e
commit 4b22c248e4
25 changed files with 870 additions and 880 deletions

View File

@@ -112,7 +112,7 @@ export function importModule (url, atts = {}, {returnDefault = false} = {}) {
};
const absURL = toAbsoluteURL(url);
const loader = `import * as m from '${absURL.replace(/'/g, "\\'")}'; window.${vector} = ${returnDefault ? 'm.default || ' : ''}m;`; // export Module
const blob = new Blob([loader], { type: 'text/javascript' });
const blob = new Blob([loader], {type: 'text/javascript'});
script.src = URL.createObjectURL(blob);
document.head.append(script);