Socket
Socket
Sign inDemoInstall

systemjs

Package Overview
Dependencies
Maintainers
2
Versions
236
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

systemjs - npm Package Compare versions

Comparing version 6.6.1 to 6.7.0

6

CHANGELOG.md

@@ -0,1 +1,7 @@

SystemJS 6.7.0
* Implement integrity attribute for systemjs-importmap scripts (https://github.com/systemjs/systemjs/commit/78072e594ebebab9124aa9fedd7e17d8303835e1)
* Deprecate the transform and use default extras (https://github.com/systemjs/systemjs/commit/5f7571a76bef210d096e672c9f011d94871a6827)
* Fetch hooks brought into core, module types extra refactoring (https://github.com/systemjs/systemjs/commit/281fdf0653663c58145f880131dceaf479add553)
* Inline named exports extra behaviours into core and deprecate (https://github.com/systemjs/systemjs/commit/3eefa2daa8d203e8d886bae7dc587eed148c5808)
SystemJS 6.6.1

@@ -2,0 +8,0 @@ * IE11 support bug fix (https://github.com/systemjs/systemjs/pull/2247)

4

dist/extras/amd.js

@@ -59,4 +59,4 @@ (function(){function errMsg(errCode, msg) {

module.exports = amdResult;
if (exports !== module.exports)
_export('default', module.exports);
_export(module.exports);
_export('default', module.exports);
}

@@ -63,0 +63,0 @@ };

@@ -1,1 +0,1 @@

!function(){function t(t,e){return(e||"")+" (SystemJS https://git.io/JvFET#"+t+")"}!function(e){function r(){throw Error(t(5))}function n(){}function i(t,e){function n(t){f.push((function(e){u[t]=e.__useDefault?e.default:e}))}for(var i={},o={exports:i},u=[],f=[],s=0,l=0;t.length>l;l++){var a=t[l],c=f.length;"require"===a?(u[l]=r,s++):"module"===a?(u[l]=o,s++):"exports"===a?(u[l]=i,s++):n(l),s&&(t[c]=a)}s&&(t.length-=s);var g=e;return[t,function(t){return t({default:i,__useDefault:!0}),{setters:f,execute:function(){var e=g.apply(i,u);void 0!==e&&(o.exports=e),i!==o.exports&&t("default",o.exports)}}}]}function o(t,e){return t instanceof Array?[t,e]:"object"==typeof t?[[],function(){return t}]:"function"==typeof t?[g,t]:void 0}function u(t,e){s||(s=e,Promise.resolve().then((function(){s=null}))),f=e,System.registerRegistry[t]=System.getRegister(),f=null}var f,s,l,a=e.System.constructor.prototype,c=[[],function(){return{}}],g=["require","exports","module"],p=a.register;a.register=function(t,e,r){l="string"==typeof t?r:e,p.apply(this,arguments)};var y=a.instantiate;a.instantiate=function(){return v=null,y.apply(this,arguments)};var v,d,h=a.getRegister;a.getRegister=function(){if(f)return f;var t=s;s=null;var e=h.call(this);if(e&&e[1]===l)return e;var r=v;return v=null,t||(r?i(r,d):e||c)},e.define=function(e,r,f){var s;if("string"==typeof e){if(s=o(r,f),v){if(!System.registerRegistry)throw Error(t(6));return u(e,i(s[0],s[1])),v=[],void(d=n)}System.registerRegistry&&u(e,i([].concat(s[0]),s[1])),e=r,r=f}s=o(e,r),v=s[0],d=s[1]},e.define.amd={}}("undefined"!=typeof self?self:global)}();//# sourceMappingURL=amd.min.js.map
!function(){function t(t,e){return(e||"")+" (SystemJS https://git.io/JvFET#"+t+")"}!function(e){function r(){throw Error(t(5))}function n(){}function i(t,e){function n(t){f.push((function(e){u[t]=e.__useDefault?e.default:e}))}for(var i={},o={exports:i},u=[],f=[],s=0,l=0;t.length>l;l++){var a=t[l],c=f.length;"require"===a?(u[l]=r,s++):"module"===a?(u[l]=o,s++):"exports"===a?(u[l]=i,s++):n(l),s&&(t[c]=a)}s&&(t.length-=s);var g=e;return[t,function(t){return t({default:i,__useDefault:!0}),{setters:f,execute:function(){var e=g.apply(i,u);void 0!==e&&(o.exports=e),t(o.exports),t("default",o.exports)}}}]}function o(t,e){return t instanceof Array?[t,e]:"object"==typeof t?[[],function(){return t}]:"function"==typeof t?[g,t]:void 0}function u(t,e){s||(s=e,Promise.resolve().then((function(){s=null}))),f=e,System.registerRegistry[t]=System.getRegister(),f=null}var f,s,l,a=e.System.constructor.prototype,c=[[],function(){return{}}],g=["require","exports","module"],p=a.register;a.register=function(t,e,r){l="string"==typeof t?r:e,p.apply(this,arguments)};var y=a.instantiate;a.instantiate=function(){return v=null,y.apply(this,arguments)};var v,d,h=a.getRegister;a.getRegister=function(){if(f)return f;var t=s;s=null;var e=h.call(this);if(e&&e[1]===l)return e;var r=v;return v=null,t||(r?i(r,d):e||c)},e.define=function(e,r,f){var s;if("string"==typeof e){if(s=o(r,f),v){if(!System.registerRegistry)throw Error(t(6));return u(e,i(s[0],s[1])),v=[],void(d=n)}System.registerRegistry&&u(e,i([].concat(s[0]),s[1])),e=r,r=f}s=o(e,r),v=s[0],d=s[1]},e.define.amd={}}("undefined"!=typeof self?self:global)}();//# sourceMappingURL=amd.min.js.map

@@ -77,2 +77,3 @@ (function(){/*

execute: function () {
_export(globalExport);
_export({ default: globalExport, __useDefault: true });

@@ -79,0 +80,0 @@ }

@@ -1,1 +0,1 @@

!function(n){function t(t){return!n.hasOwnProperty(t)||!isNaN(t)&&n.length>t||c&&n[t]&&"undefined"!=typeof window&&n[t].parent===window}var r,e,i,u=n.System.constructor.prototype,f=u.import;u.import=function(u,o){return function(){for(var u in r=e=void 0,n)t(u)||(r?e||(e=u):r=u,i=u)}(),f.call(this,u,o)};var o=[[],function(){return{}}],a=u.getRegister;u.getRegister=function(){var u=a.call(this);if(u)return u;var f,c=function(){var u,f=0;for(var o in n)if(!t(o)){if(0===f&&o!==r||1===f&&o!==e)return o;f++,u=o}if(u!==i)return u}();if(!c)return o;try{f=n[c]}catch(d){return o}return[[],function(n){return{execute:function(){n({default:f,__useDefault:!0})}}}]};var c="undefined"!=typeof navigator&&-1!==navigator.userAgent.indexOf("Trident")}("undefined"!=typeof self?self:global);//# sourceMappingURL=global.min.js.map
!function(n){function t(t){return!n.hasOwnProperty(t)||!isNaN(t)&&n.length>t||c&&n[t]&&"undefined"!=typeof window&&n[t].parent===window}var r,e,i,u=n.System.constructor.prototype,f=u.import;u.import=function(u,o){return function(){for(var u in r=e=void 0,n)t(u)||(r?e||(e=u):r=u,i=u)}(),f.call(this,u,o)};var o=[[],function(){return{}}],a=u.getRegister;u.getRegister=function(){var u=a.call(this);if(u)return u;var f,c=function(){var u,f=0;for(var o in n)if(!t(o)){if(0===f&&o!==r||1===f&&o!==e)return o;f++,u=o}if(u!==i)return u}();if(!c)return o;try{f=n[c]}catch(d){return o}return[[],function(n){return{execute:function(){n(f),n({default:f,__useDefault:!0})}}}]};var c="undefined"!=typeof navigator&&-1!==navigator.userAgent.indexOf("Trident")}("undefined"!=typeof self?self:global);//# sourceMappingURL=global.min.js.map

@@ -1,101 +0,70 @@

(function(){function errMsg(errCode, msg) {
return (msg || "") + " (SystemJS Error#" + errCode + " " + "https://git.io/JvFET#" + errCode + ")";
}/*
* Loads JSON, CSS, Wasm module types based on file extensions
* Supports application/javascript falling back to JS eval
(function(){/*
* Loads JSON, CSS, Wasm module types based on file extension
* filters and content type verifications
*/
(function(global) {
var systemJSPrototype = global.System.constructor.prototype;
var instantiate = systemJSPrototype.instantiate;
var moduleTypesRegEx = /\.(css|html|json|wasm)$/;
var moduleTypesRegEx = /^[^#?]+\.(css|html|json|wasm)([?#].*)?$/;
systemJSPrototype.shouldFetch = function (url) {
var path = url.split('?')[0].split('#')[0];
var ext = path.slice(path.lastIndexOf('.'));
return ext.match(moduleTypesRegEx);
return moduleTypesRegEx.test(url);
};
systemJSPrototype.fetch = function (url) {
return fetch(url);
};
systemJSPrototype.instantiate = function (url, parent) {
var loader = this;
if (this.shouldFetch(url)) {
return this.fetch(url)
.then(function (res) {
if (!res.ok)
throw Error(errMsg(7, res.status + ' ' + res.statusText + ', loading ' + url + (parent ? ' from ' + parent : '')));
var contentType = res.headers.get('content-type');
if (!contentType)
throw Error(errMsg(4, 'Missing header "Content-Type", loading ' + url + (parent ? ' from ' + parent : '')));
if (contentType.match(/^(text|application)\/(x-)?javascript(;|$)/)) {
return res.text().then(function (source) {
(0, eval)(source);
return loader.getRegister();
});
}
else if (contentType.match(/^application\/json(;|$)/)) {
return res.text().then(function (source) {
return [[], function (_export) {
return {
execute: function () {
_export('default', JSON.parse(source));
}
};
}];
});
}
else if (contentType.match(/^text\/css(;|$)/)) {
return res.text().then(function (source) {
return [[], function (_export) {
return {
execute: function () {
// Relies on a Constructable Stylesheet polyfill
var stylesheet = new CSSStyleSheet();
stylesheet.replaceSync(source);
_export('default', stylesheet);
}
};
}];
});
}
else if (contentType.match(/^application\/wasm(;|$)/)) {
return (WebAssembly.compileStreaming ? WebAssembly.compileStreaming(res) : res.arrayBuffer().then(WebAssembly.compile))
.then(function (module) {
var deps = [];
var setters = [];
var importObj = {};
// we can only set imports if supported (eg early Safari doesnt support)
if (WebAssembly.Module.imports)
WebAssembly.Module.imports(module).forEach(function (impt) {
var key = impt.module;
if (deps.indexOf(key) === -1) {
deps.push(key);
setters.push(function (m) {
importObj[key] = m;
});
}
});
return [deps, function (_export) {
return {
setters: setters,
execute: function () {
return WebAssembly.instantiate(module, importObj)
.then(function (instance) {
_export(instance.exports);
});
}
};
}];
});
}
else {
throw Error(errMsg(4, 'Unknown module type "' + contentType + '"'));
}
});
}
return instantiate.apply(this, arguments);
var jsonContentType = /^application\/json(;|$)/;
var cssContentType = /^text\/css(;|$)/;
var wasmContentType = /^application\/wasm(;|$)/;
var fetch = systemJSPrototype.fetch;
systemJSPrototype.fetch = function (url, options) {
return fetch(url, options)
.then(function (res) {
if (!res.ok)
return res;
var contentType = res.headers.get('content-type');
if (jsonContentType.test(contentType))
return res.json()
.then(function (json) {
return new Response(new Blob([
'System.register([],function(e){return{execute:function(){e("default",' + JSON.stringify(json) + ')}}})'
], {
type: 'application/javascript'
}));
});
if (cssContentType.test(contentType))
return res.text()
.then(function (source) {
return new Response(new Blob([
'System.register([],function(e){return{execute:function(){var s=new CSSStyleSheet();s.replaceSync(' + JSON.stringify(source) + ');e("default",s)}}})'
], {
type: 'application/javascript'
}));
});
if (wasmContentType.test(contentType))
return (WebAssembly.compileStreaming ? WebAssembly.compileStreaming(res) : res.arrayBuffer().then(WebAssembly.compile))
.then(function (module) {
if (!global.System.wasmModules)
global.System.wasmModules = Object.create(null);
global.System.wasmModules[url] = module;
// we can only set imports if supported (eg early Safari doesnt support)
var deps = [];
var setterSources = [];
if (WebAssembly.Module.imports)
WebAssembly.Module.imports(module).forEach(function (impt) {
var key = JSON.stringify(impt.module);
if (deps.indexOf(key) === -1) {
deps.push(key);
setterSources.push('function(m){i[' + key + ']=m}');
}
});
return new Response(new Blob([
'System.register([' + deps.join(',') + '],function(e){var i={};return{setters:[' + setterSources.join(',') +
'],execute:function(){return WebAssembly.instantiate(System.wasmModules[' + JSON.stringify(url) +
'],i).then(function(m){e(m.exports)})}}})'
], {
type: 'application/javascript'
}));
});
return res;
});
};
})(typeof self !== 'undefined' ? self : global);}());

@@ -1,1 +0,1 @@

!function(){function t(t,e){return(e||"")+" (SystemJS https://git.io/JvFET#"+t+")"}!function(e){var n=e.System.constructor.prototype,r=n.instantiate;n.shouldFetch=function(t){var e=t.split("?")[0].split("#")[0];return e.slice(e.lastIndexOf(".")).match(/\.(css|html|json|wasm)$/)},n.fetch=function(t){return fetch(t)},n.instantiate=function(e,n){var i=this;return this.shouldFetch(e)?this.fetch(e).then((function(r){if(!r.ok)throw Error(t(7,[r.status,r.statusText,e,n].join(", ")));var s=r.headers.get("content-type");if(!s)throw Error(t(4,[e,n]));if(s.match(/^(text|application)\/(x-)?javascript(;|$)/))return r.text().then((function(t){return(0,eval)(t),i.getRegister()}));if(s.match(/^application\/json(;|$)/))return r.text().then((function(t){return[[],function(e){return{execute:function(){e("default",JSON.parse(t))}}}]}));if(s.match(/^text\/css(;|$)/))return r.text().then((function(t){return[[],function(e){return{execute:function(){var n=new CSSStyleSheet;n.replaceSync(t),e("default",n)}}}]}));if(s.match(/^application\/wasm(;|$)/))return(WebAssembly.compileStreaming?WebAssembly.compileStreaming(r):r.arrayBuffer().then(WebAssembly.compile)).then((function(t){var e=[],n=[],r={};return WebAssembly.Module.imports&&WebAssembly.Module.imports(t).forEach((function(t){var i=t.module;-1===e.indexOf(i)&&(e.push(i),n.push((function(t){r[i]=t})))})),[e,function(e){return{setters:n,execute:function(){return WebAssembly.instantiate(t,r).then((function(t){e(t.exports)}))}}}]}));throw Error(t(4,s))})):r.apply(this,arguments)}}("undefined"!=typeof self?self:global)}();//# sourceMappingURL=module-types.min.js.map
!function(e){var t=e.System.constructor.prototype,n=/^[^#?]+\.(css|html|json|wasm)([?#].*)?$/;t.shouldFetch=function(e){return n.test(e)};var s=/^application\/json(;|$)/,r=/^text\/css(;|$)/,i=/^application\/wasm(;|$)/,o=t.fetch;t.fetch=function(t,n){return o(t,n).then((function(n){if(!n.ok)return n;var o=n.headers.get("content-type");return s.test(o)?n.json().then((function(e){return new Response(new Blob(['System.register([],function(e){return{execute:function(){e("default",'+JSON.stringify(e)+")}}})"],{type:"application/javascript"}))})):r.test(o)?n.text().then((function(e){return new Response(new Blob(["System.register([],function(e){return{execute:function(){var s=new CSSStyleSheet();s.replaceSync("+JSON.stringify(e)+');e("default",s)}}})'],{type:"application/javascript"}))})):i.test(o)?(WebAssembly.compileStreaming?WebAssembly.compileStreaming(n):n.arrayBuffer().then(WebAssembly.compile)).then((function(n){e.System.wasmModules||(e.System.wasmModules=Object.create(null)),e.System.wasmModules[t]=n;var s=[],r=[];return WebAssembly.Module.imports&&WebAssembly.Module.imports(n).forEach((function(e){var t=JSON.stringify(e.module);-1===s.indexOf(t)&&(s.push(t),r.push("function(m){i["+t+"]=m}"))})),new Response(new Blob(["System.register(["+s.join(",")+"],function(e){var i={};return{setters:["+r.join(",")+"],execute:function(){return WebAssembly.instantiate(System.wasmModules["+JSON.stringify(t)+"],i).then(function(m){e(m.exports)})}}})"],{type:"application/javascript"}))})):n}))}}("undefined"!=typeof self?self:global);//# sourceMappingURL=module-types.min.js.map
(function(){/*
* Named exports support for legacy module formats in SystemJS 2.0
*
* Note: This extra is deprecated as the behaviour is now the default in core,
* so will be removed in the next major.
*/

@@ -4,0 +7,0 @@ (function (global) {

@@ -5,2 +5,4 @@ (function(){function errMsg(errCode, msg) {

* Support for a "transform" loader interface
*
* Note: This extra is deprecated and will be removed in the next major.
*/

@@ -7,0 +9,0 @@ (function (global) {

(function(){/*
* Interop for AMD modules to return the direct AMD binding instead of a
* `{ default: amdModule }` object from `System.import`
*
* Note: This extra is deprecated and will be removed in the next major.
*/

@@ -5,0 +7,0 @@ (function (global) {

/*
* SJS 6.6.1
* SJS 6.7.0
* Minimal SystemJS Build
*/
(function () {
function errMsg(errCode, msg) {

@@ -289,3 +290,3 @@ return (msg || "") + " (SystemJS https://git.io/JvFET#" + errCode + ")";

var changed = false;
if (typeof name !== 'object') {
if (typeof name === 'string') {
if (!(name in ns) || ns[name] !== value) {

@@ -468,7 +469,7 @@ ns[name] = value;

load.E = null; // indicates completion
if (!true) triggerOnload(loader, load, null, true);
if (!true) ;
}, function (err) {
load.er = err;
load.E = null;
if (!true) triggerOnload(loader, load, err, true);
if (!true) ;
else throw err;

@@ -480,3 +481,3 @@ });

load.C = load.n;
if (!true) triggerOnload(loader, load, null, true);
if (!true) ;
}

@@ -532,3 +533,3 @@ catch (err) {

script.sp = true;
var fetchPromise = script.src ? fetch(script.src).then(function (res) {
var fetchPromise = script.src ? fetch(script.src, { integrity: script.integrity }).then(function (res) {
return res.text();

@@ -639,2 +640,34 @@ }) : script.innerHTML;

/*
* Fetch loader, sets up shouldFetch and fetch hooks
*/
systemJSPrototype.shouldFetch = function () {
return false;
};
if (typeof fetch !== 'undefined')
systemJSPrototype.fetch = fetch;
var instantiate = systemJSPrototype.instantiate;
var jsContentTypeRegEx = /^(text|application)\/(x-)?javascript(;|$)/;
systemJSPrototype.instantiate = function (url, parent) {
var loader = this;
if (!this.shouldFetch(url))
return instantiate.apply(this, arguments);
return this.fetch(url, {
credentials: 'same-origin',
integrity: importMap.integrity[url]
})
.then(function (res) {
if (!res.ok)
throw Error(errMsg(7, [res.status, res.statusText, url, parent].join(', ') ));
var contentType = res.headers.get('content-type');
if (!contentType || !jsContentTypeRegEx.test(contentType))
throw Error(errMsg(4, contentType ));
return res.text().then(function (source) {
(0, eval)(source);
return loader.getRegister();
});
});
};
systemJSPrototype.resolve = function (id, parentUrl) {

@@ -641,0 +674,0 @@ parentUrl = parentUrl || !true || baseUrl;

@@ -1,2 +0,2 @@

!function(){function e(e,n){return(n||"")+" (SystemJS https://git.io/JvFET#"+e+")"}function n(e,n){if(-1!==e.indexOf("\\")&&(e=e.replace(/\\/g,"/")),"/"===e[0]&&"/"===e[1])return n.slice(0,n.indexOf(":")+1)+e;if("."===e[0]&&("/"===e[1]||"."===e[1]&&("/"===e[2]||2===e.length&&(e+="/"))||1===e.length&&(e+="/"))||"/"===e[0]){var t,r=n.slice(0,n.indexOf(":")+1);if(t="/"===n[r.length+1]?"file:"!==r?(t=n.slice(r.length+2)).slice(t.indexOf("/")+1):n.slice(8):n.slice(r.length+("/"===n[r.length])),"/"===e[0])return n.slice(0,n.length-t.length-1)+e;for(var i=t.slice(0,t.lastIndexOf("/")+1)+e,o=[],c=-1,u=0;i.length>u;u++)-1!==c?"/"===i[u]&&(o.push(i.slice(c,u+1)),c=-1):"."===i[u]?"."!==i[u+1]||"/"!==i[u+2]&&u+2!==i.length?"/"===i[u+1]||u+1===i.length?u+=1:c=u:(o.pop(),u+=2):c=u;return-1!==c&&o.push(i.slice(c)),n.slice(0,n.length-t.length)+o.join("")}}function t(e,t){return n(e,t)||(-1!==e.indexOf(":")?e:n("./"+e,t))}function r(e,t,r,i,o){for(var s in e){var f=n(s,r)||s,l=e[s];if("string"==typeof l){var a=u(i,n(l,r)||l,o);a?t[f]=a:c("W1",s,l)}}}function i(e,n){if(n[e])return e;var t=e.length;do{var r=e.slice(0,t+1);if(r in n)return r}while(-1!==(t=e.lastIndexOf("/",t-1)))}function o(e,n){var t=i(e,n);if(t){var r=n[t];if(null===r)return;if(t.length>=e.length||"/"===r[r.length-1])return r+e.slice(t.length);c("W2",t,r)}}function c(n,t,r){console.warn(e(n,[r,t].join(", ")))}function u(e,n,t){for(var r=e.scopes,c=t&&i(t,r);c;){var u=o(n,r[c]);if(u)return u;c=i(c.slice(0,c.lastIndexOf("/")),r)}return o(n,e.imports)||-1!==n.indexOf(":")&&n}function s(){this[O]={}}function f(n,t,r){var i=n[O][t];if(i)return i;var o=[],c=Object.create(null);E&&Object.defineProperty(c,E,{value:"Module"});var u=Promise.resolve().then((function(){return n.instantiate(t,r)})).then((function(r){if(!r)throw Error(e(2,t));var u=r[1]((function(e,n){i.h=!0;var t=!1;if("object"!=typeof e)e in c&&c[e]===n||(c[e]=n,t=!0);else{for(var r in e)n=e[r],r in c&&c[r]===n||(c[r]=n,t=!0);e.__esModule&&(c.__esModule=e.__esModule)}if(t)for(var u=0;o.length>u;u++){var s=o[u];s&&s(c)}return n}),2===r[1].length?{import:function(e){return n.import(e,t)},meta:n.createContext(t)}:void 0);return i.e=u.execute||function(){},[r[0],u.setters||[]]})),s=u.then((function(e){return Promise.all(e[0].map((function(r,i){var o=e[1][i];return Promise.resolve(n.resolve(r,t)).then((function(e){var r=f(n,e,t);return Promise.resolve(r.I).then((function(){return o&&(r.i.push(o),!r.h&&r.I||o(r.n)),r}))}))}))).then((function(e){i.d=e}),!1)}));return s.catch((function(e){i.e=null,i.er=e})),i=n[O][t]={id:t,i:o,n:c,I:u,L:s,h:!1,d:void 0,e:void 0,er:void 0,E:void 0,C:void 0}}function l(){[].forEach.call(document.querySelectorAll("script"),(function(n){if(!n.sp)if("systemjs-module"===n.type){if(n.sp=!0,!n.src)return;System.import("import:"===n.src.slice(0,7)?n.src.slice(7):t(n.src,a))}else if("systemjs-importmap"===n.type){n.sp=!0;var i=n.src?fetch(n.src).then((function(e){return e.text()})):n.innerHTML;j=j.then((function(){return i})).then((function(i){!function(n,i,o){try{var c=JSON.parse(i)}catch(u){throw Error(e(1))}!function(e,n,i){var o;for(o in e.imports&&r(e.imports,i.imports,n,i,null),e.scopes||{}){var c=t(o,n);r(e.scopes[o],i.scopes[c]||(i.scopes[c]={}),n,i,c)}for(o in e.depcache||{})i.depcache[t(o,n)]=e.depcache[o];for(o in e.integrity||{})i.integrity[t(o,n)]=e.integrity[o]}(c,o,n)}(b,i,n.src||a)}))}}))}var a,h="undefined"!=typeof Symbol,v="undefined"!=typeof self,d="undefined"!=typeof document,p=v?self:global;if(d){var m=document.querySelector("base[href]");m&&(a=m.href)}if(!a&&"undefined"!=typeof location){var g=(a=location.href.split("#")[0].split("?")[0]).lastIndexOf("/");-1!==g&&(a=a.slice(0,g+1))}var y,E=h&&Symbol.toStringTag,O=h?Symbol():"@",w=s.prototype;w.import=function(e,n){var t=this;return Promise.resolve(t.prepareImport()).then((function(){return t.resolve(e,n)})).then((function(e){var n=f(t,e);return n.C||function(e,n){return n.C=function e(n,t,r){if(!r[t.id])return r[t.id]=!0,Promise.resolve(t.L).then((function(){return Promise.all(t.d.map((function(t){return e(n,t,r)})))}))}(e,n,{}).then((function(){return function e(n,t,r){function i(){try{var e=t.e.call(S);if(e)return e=e.then((function(){t.C=t.n,t.E=null}),(function(e){throw t.er=e,t.E=null,e})),t.E=t.E||e;t.C=t.n}catch(n){throw t.er=n,n}finally{t.L=t.I=void 0,t.e=null}}if(!r[t.id]){if(r[t.id]=!0,!t.e){if(t.er)throw t.er;return t.E?t.E:void 0}var o;return t.d.forEach((function(i){try{var c=e(n,i,r);c&&(o=o||[]).push(c)}catch(u){throw t.e=null,t.er=u,u}})),o?Promise.all(o).then(i,(function(e){throw t.e=null,t.er=e,e})):i()}}(e,n,{})})).then((function(){return n.n}))}(t,n)}))},w.createContext=function(e){var n=this;return{url:e,resolve:function(t,r){return Promise.resolve(n.resolve(t,r||e))}}},w.register=function(e,n){y=[e,n]},w.getRegister=function(){var e=y;return y=void 0,e};var S=Object.freeze(Object.create(null));p.System=new s;var x,P,j=Promise.resolve(),b={imports:{},scopes:{},depcache:{},integrity:{}},C=d;if(w.prepareImport=function(e){return(C||e)&&(l(),C=!1),j},d&&(l(),window.addEventListener("DOMContentLoaded",l)),d){window.addEventListener("error",(function(e){L=e.filename,M=e.error}));var I=location.origin}w.createScript=function(e){var n=document.createElement("script");n.async=!0,e.indexOf(I+"/")&&(n.crossOrigin="anonymous");var t=b.integrity[e];return t&&(n.integrity=t),n.src=e,n};var L,M,T={},_=w.register;w.register=function(e,n){if(d&&"loading"===document.readyState&&"string"!=typeof e){var t=document.getElementsByTagName("script"),r=t[t.length-1],i=r&&r.src;if(i){x=e;var o=this;P=setTimeout((function(){T[i]=[e,n],o.import(i)}))}}else x=void 0;return _.call(this,e,n)},w.instantiate=function(n,t){var r=T[n];if(r)return delete T[n],r;var i=this;return new Promise((function(r,o){var c=w.createScript(n);c.addEventListener("error",(function(){o(Error(e(3,[n,t].join(", "))))})),c.addEventListener("load",(function(){if(document.head.removeChild(c),L===n)o(M);else{var e=i.getRegister();e&&e[0]===x&&clearTimeout(P),r(e)}})),document.head.appendChild(c)}))},w.resolve=function(t,r){return u(b,n(t,r=r||a)||t,r)||function(n,t){throw Error(e(8,[n,t].join(", ")))}(t,r)};var J=w.instantiate;w.instantiate=function(e,n){var t=b.depcache[e];if(t)for(var r=0;t.length>r;r++)f(this,this.resolve(t[r],e),e);return J.call(this,e,n)},v&&"function"==typeof importScripts&&(w.instantiate=function(e){var n=this;return Promise.resolve().then((function(){return importScripts(e),n.getRegister()}))})}();
!function(){function e(e,t){return(t||"")+" (SystemJS https://git.io/JvFET#"+e+")"}function t(e,t){if(-1!==e.indexOf("\\")&&(e=e.replace(/\\/g,"/")),"/"===e[0]&&"/"===e[1])return t.slice(0,t.indexOf(":")+1)+e;if("."===e[0]&&("/"===e[1]||"."===e[1]&&("/"===e[2]||2===e.length&&(e+="/"))||1===e.length&&(e+="/"))||"/"===e[0]){var n,r=t.slice(0,t.indexOf(":")+1);if(n="/"===t[r.length+1]?"file:"!==r?(n=t.slice(r.length+2)).slice(n.indexOf("/")+1):t.slice(8):t.slice(r.length+("/"===t[r.length])),"/"===e[0])return t.slice(0,t.length-n.length-1)+e;for(var i=n.slice(0,n.lastIndexOf("/")+1)+e,o=[],c=-1,s=0;i.length>s;s++)-1!==c?"/"===i[s]&&(o.push(i.slice(c,s+1)),c=-1):"."===i[s]?"."!==i[s+1]||"/"!==i[s+2]&&s+2!==i.length?"/"===i[s+1]||s+1===i.length?s+=1:c=s:(o.pop(),s+=2):c=s;return-1!==c&&o.push(i.slice(c)),t.slice(0,t.length-n.length)+o.join("")}}function n(e,n){return t(e,n)||(-1!==e.indexOf(":")?e:t("./"+e,n))}function r(e,n,r,i,o){for(var u in e){var f=t(u,r)||u,a=e[u];if("string"==typeof a){var l=s(i,t(a,r)||a,o);l?n[f]=l:c("W1",u,a)}}}function i(e,t){if(t[e])return e;var n=e.length;do{var r=e.slice(0,n+1);if(r in t)return r}while(-1!==(n=e.lastIndexOf("/",n-1)))}function o(e,t){var n=i(e,t);if(n){var r=t[n];if(null===r)return;if(n.length>=e.length||"/"===r[r.length-1])return r+e.slice(n.length);c("W2",n,r)}}function c(t,n,r){console.warn(e(t,[r,n].join(", ")))}function s(e,t,n){for(var r=e.scopes,c=n&&i(n,r);c;){var s=o(t,r[c]);if(s)return s;c=i(c.slice(0,c.lastIndexOf("/")),r)}return o(t,e.imports)||-1!==t.indexOf(":")&&t}function u(){this[x]={}}function f(t,n,r){var i=t[x][n];if(i)return i;var o=[],c=Object.create(null);E&&Object.defineProperty(c,E,{value:"Module"});var s=Promise.resolve().then((function(){return t.instantiate(n,r)})).then((function(r){if(!r)throw Error(e(2,n));var s=r[1]((function(e,t){i.h=!0;var n=!1;if("string"==typeof e)e in c&&c[e]===t||(c[e]=t,n=!0);else{for(var r in e)t=e[r],r in c&&c[r]===t||(c[r]=t,n=!0);e.__esModule&&(c.__esModule=e.__esModule)}if(n)for(var s=0;o.length>s;s++){var u=o[s];u&&u(c)}return t}),2===r[1].length?{import:function(e){return t.import(e,n)},meta:t.createContext(n)}:void 0);return i.e=s.execute||function(){},[r[0],s.setters||[]]})),u=s.then((function(e){return Promise.all(e[0].map((function(r,i){var o=e[1][i];return Promise.resolve(t.resolve(r,n)).then((function(e){var r=f(t,e,n);return Promise.resolve(r.I).then((function(){return o&&(r.i.push(o),!r.h&&r.I||o(r.n)),r}))}))}))).then((function(e){i.d=e}),!1)}));return u.catch((function(e){i.e=null,i.er=e})),i=t[x][n]={id:n,i:o,n:c,I:s,L:u,h:!1,d:void 0,e:void 0,er:void 0,E:void 0,C:void 0}}function a(){[].forEach.call(document.querySelectorAll("script"),(function(t){if(!t.sp)if("systemjs-module"===t.type){if(t.sp=!0,!t.src)return;System.import("import:"===t.src.slice(0,7)?t.src.slice(7):n(t.src,l))}else if("systemjs-importmap"===t.type){t.sp=!0;var i=t.src?fetch(t.src,{integrity:t.integrity}).then((function(e){return e.text()})):t.innerHTML;j=j.then((function(){return i})).then((function(i){!function(t,i,o){try{var c=JSON.parse(i)}catch(s){throw Error(e(1))}!function(e,t,i){var o;for(o in e.imports&&r(e.imports,i.imports,t,i,null),e.scopes||{}){var c=n(o,t);r(e.scopes[o],i.scopes[c]||(i.scopes[c]={}),t,i,c)}for(o in e.depcache||{})i.depcache[n(o,t)]=e.depcache[o];for(o in e.integrity||{})i.integrity[n(o,t)]=e.integrity[o]}(c,o,t)}(C,i,t.src||l)}))}}))}var l,h="undefined"!=typeof Symbol,v="undefined"!=typeof self,d="undefined"!=typeof document,p=v?self:global;if(d){var g=document.querySelector("base[href]");g&&(l=g.href)}if(!l&&"undefined"!=typeof location){var m=(l=location.href.split("#")[0].split("?")[0]).lastIndexOf("/");-1!==m&&(l=l.slice(0,m+1))}var y,E=h&&Symbol.toStringTag,x=h?Symbol():"@",w=u.prototype;w.import=function(e,t){var n=this;return Promise.resolve(n.prepareImport()).then((function(){return n.resolve(e,t)})).then((function(e){var t=f(n,e);return t.C||function(e,t){return t.C=function e(t,n,r){if(!r[n.id])return r[n.id]=!0,Promise.resolve(n.L).then((function(){return Promise.all(n.d.map((function(n){return e(t,n,r)})))}))}(e,t,{}).then((function(){return function e(t,n,r){function i(){try{var e=n.e.call(O);if(e)return e=e.then((function(){n.C=n.n,n.E=null}),(function(e){throw n.er=e,n.E=null,e})),n.E=n.E||e;n.C=n.n}catch(t){throw n.er=t,t}finally{n.L=n.I=void 0,n.e=null}}if(!r[n.id]){if(r[n.id]=!0,!n.e){if(n.er)throw n.er;return n.E?n.E:void 0}var o;return n.d.forEach((function(i){try{var c=e(t,i,r);c&&(o=o||[]).push(c)}catch(s){throw n.e=null,n.er=s,s}})),o?Promise.all(o).then(i,(function(e){throw n.e=null,n.er=e,e})):i()}}(e,t,{})})).then((function(){return t.n}))}(n,t)}))},w.createContext=function(e){var t=this;return{url:e,resolve:function(n,r){return Promise.resolve(t.resolve(n,r||e))}}},w.register=function(e,t){y=[e,t]},w.getRegister=function(){var e=y;return y=void 0,e};var O=Object.freeze(Object.create(null));p.System=new u;var S,P,j=Promise.resolve(),C={imports:{},scopes:{},depcache:{},integrity:{}},I=d;if(w.prepareImport=function(e){return(I||e)&&(a(),I=!1),j},d&&(a(),window.addEventListener("DOMContentLoaded",a)),d){window.addEventListener("error",(function(e){L=e.filename,T=e.error}));var b=location.origin}w.createScript=function(e){var t=document.createElement("script");t.async=!0,e.indexOf(b+"/")&&(t.crossOrigin="anonymous");var n=C.integrity[e];return n&&(t.integrity=n),t.src=e,t};var L,T,M={},_=w.register;w.register=function(e,t){if(d&&"loading"===document.readyState&&"string"!=typeof e){var n=document.getElementsByTagName("script"),r=n[n.length-1],i=r&&r.src;if(i){S=e;var o=this;P=setTimeout((function(){M[i]=[e,t],o.import(i)}))}}else S=void 0;return _.call(this,e,t)},w.instantiate=function(t,n){var r=M[t];if(r)return delete M[t],r;var i=this;return new Promise((function(r,o){var c=w.createScript(t);c.addEventListener("error",(function(){o(Error(e(3,[t,n].join(", "))))})),c.addEventListener("load",(function(){if(document.head.removeChild(c),L===t)o(T);else{var e=i.getRegister();e&&e[0]===S&&clearTimeout(P),r(e)}})),document.head.appendChild(c)}))},w.shouldFetch=function(){return!1},"undefined"!=typeof fetch&&(w.fetch=fetch);var R=w.instantiate,F=/^(text|application)\/(x-)?javascript(;|$)/;w.instantiate=function(t,n){var r=this;return this.shouldFetch(t)?this.fetch(t,{credentials:"same-origin",integrity:C.integrity[t]}).then((function(i){if(!i.ok)throw Error(e(7,[i.status,i.statusText,t,n].join(", ")));var o=i.headers.get("content-type");if(!o||!F.test(o))throw Error(e(4,o));return i.text().then((function(e){return(0,eval)(e),r.getRegister()}))})):R.apply(this,arguments)},w.resolve=function(n,r){return s(C,t(n,r=r||l)||n,r)||function(t,n){throw Error(e(8,[t,n].join(", ")))}(n,r)};var J=w.instantiate;w.instantiate=function(e,t){var n=C.depcache[e];if(n)for(var r=0;n.length>r;r++)f(this,this.resolve(n[r],e),e);return J.call(this,e,t)},v&&"function"==typeof importScripts&&(w.instantiate=function(e){var t=this;return Promise.resolve().then((function(){return importScripts(e),t.getRegister()}))})}();
//# sourceMappingURL=s.min.js.map
/*
* SystemJS 6.6.1
* SystemJS 6.7.0
*/
(function () {
function errMsg(errCode, msg) {

@@ -291,3 +292,3 @@ return (msg || "") + " (SystemJS Error#" + errCode + " " + "https://git.io/JvFET#" + errCode + ")";

var changed = false;
if (typeof name !== 'object') {
if (typeof name === 'string') {
if (!(name in ns) || ns[name] !== value) {

@@ -481,3 +482,2 @@ ns[name] = value;

if (!false) triggerOnload(loader, load, err, true);
else throw err;
});

@@ -539,3 +539,3 @@ return load.E = load.E || execPromise;

script.sp = true;
var fetchPromise = script.src ? fetch(script.src).then(function (res) {
var fetchPromise = script.src ? fetch(script.src, { integrity: script.integrity }).then(function (res) {
return res.text();

@@ -646,2 +646,34 @@ }) : script.innerHTML;

/*
* Fetch loader, sets up shouldFetch and fetch hooks
*/
systemJSPrototype.shouldFetch = function () {
return false;
};
if (typeof fetch !== 'undefined')
systemJSPrototype.fetch = fetch;
var instantiate = systemJSPrototype.instantiate;
var jsContentTypeRegEx = /^(text|application)\/(x-)?javascript(;|$)/;
systemJSPrototype.instantiate = function (url, parent) {
var loader = this;
if (!this.shouldFetch(url))
return instantiate.apply(this, arguments);
return this.fetch(url, {
credentials: 'same-origin',
integrity: importMap.integrity[url]
})
.then(function (res) {
if (!res.ok)
throw Error(errMsg(7, res.status + ' ' + res.statusText + ', loading ' + url + (parent ? ' from ' + parent : '')));
var contentType = res.headers.get('content-type');
if (!contentType || !jsContentTypeRegEx.test(contentType))
throw Error(errMsg(4, 'Unknown Content-Type "' + contentType + '", loading ' + url + (parent ? ' from ' + parent : '')));
return res.text().then(function (source) {
(0, eval)(source);
return loader.getRegister();
});
});
};
systemJSPrototype.resolve = function (id, parentUrl) {

@@ -755,2 +787,3 @@ parentUrl = parentUrl || !true || baseUrl;

execute: function () {
_export(globalExport);
_export({ default: globalExport, __useDefault: true });

@@ -772,98 +805,69 @@ }

/*
* Loads JSON, CSS, Wasm module types based on file extensions
* Supports application/javascript falling back to JS eval
* Loads JSON, CSS, Wasm module types based on file extension
* filters and content type verifications
*/
(function(global) {
var systemJSPrototype = global.System.constructor.prototype;
var instantiate = systemJSPrototype.instantiate;
var moduleTypesRegEx = /\.(css|html|json|wasm)$/;
var moduleTypesRegEx = /^[^#?]+\.(css|html|json|wasm)([?#].*)?$/;
systemJSPrototype.shouldFetch = function (url) {
var path = url.split('?')[0].split('#')[0];
var ext = path.slice(path.lastIndexOf('.'));
return ext.match(moduleTypesRegEx);
return moduleTypesRegEx.test(url);
};
systemJSPrototype.fetch = function (url) {
return fetch(url);
};
systemJSPrototype.instantiate = function (url, parent) {
var loader = this;
if (this.shouldFetch(url)) {
return this.fetch(url)
.then(function (res) {
if (!res.ok)
throw Error(errMsg(7, res.status + ' ' + res.statusText + ', loading ' + url + (parent ? ' from ' + parent : '')));
var contentType = res.headers.get('content-type');
if (!contentType)
throw Error(errMsg(4, 'Missing header "Content-Type", loading ' + url + (parent ? ' from ' + parent : '')));
if (contentType.match(/^(text|application)\/(x-)?javascript(;|$)/)) {
return res.text().then(function (source) {
(0, eval)(source);
return loader.getRegister();
});
}
else if (contentType.match(/^application\/json(;|$)/)) {
return res.text().then(function (source) {
return [[], function (_export) {
return {
execute: function () {
_export('default', JSON.parse(source));
}
};
}];
});
}
else if (contentType.match(/^text\/css(;|$)/)) {
return res.text().then(function (source) {
return [[], function (_export) {
return {
execute: function () {
// Relies on a Constructable Stylesheet polyfill
var stylesheet = new CSSStyleSheet();
stylesheet.replaceSync(source);
_export('default', stylesheet);
}
};
}];
});
}
else if (contentType.match(/^application\/wasm(;|$)/)) {
return (WebAssembly.compileStreaming ? WebAssembly.compileStreaming(res) : res.arrayBuffer().then(WebAssembly.compile))
.then(function (module) {
var deps = [];
var setters = [];
var importObj = {};
// we can only set imports if supported (eg early Safari doesnt support)
if (WebAssembly.Module.imports)
WebAssembly.Module.imports(module).forEach(function (impt) {
var key = impt.module;
if (deps.indexOf(key) === -1) {
deps.push(key);
setters.push(function (m) {
importObj[key] = m;
});
}
});
return [deps, function (_export) {
return {
setters: setters,
execute: function () {
return WebAssembly.instantiate(module, importObj)
.then(function (instance) {
_export(instance.exports);
});
}
};
}];
});
}
else {
throw Error(errMsg(4, 'Unknown module type "' + contentType + '"'));
}
});
}
return instantiate.apply(this, arguments);
var jsonContentType = /^application\/json(;|$)/;
var cssContentType = /^text\/css(;|$)/;
var wasmContentType = /^application\/wasm(;|$)/;
var fetch = systemJSPrototype.fetch;
systemJSPrototype.fetch = function (url, options) {
return fetch(url, options)
.then(function (res) {
if (!res.ok)
return res;
var contentType = res.headers.get('content-type');
if (jsonContentType.test(contentType))
return res.json()
.then(function (json) {
return new Response(new Blob([
'System.register([],function(e){return{execute:function(){e("default",' + JSON.stringify(json) + ')}}})'
], {
type: 'application/javascript'
}));
});
if (cssContentType.test(contentType))
return res.text()
.then(function (source) {
return new Response(new Blob([
'System.register([],function(e){return{execute:function(){var s=new CSSStyleSheet();s.replaceSync(' + JSON.stringify(source) + ');e("default",s)}}})'
], {
type: 'application/javascript'
}));
});
if (wasmContentType.test(contentType))
return (WebAssembly.compileStreaming ? WebAssembly.compileStreaming(res) : res.arrayBuffer().then(WebAssembly.compile))
.then(function (module) {
if (!global.System.wasmModules)
global.System.wasmModules = Object.create(null);
global.System.wasmModules[url] = module;
// we can only set imports if supported (eg early Safari doesnt support)
var deps = [];
var setterSources = [];
if (WebAssembly.Module.imports)
WebAssembly.Module.imports(module).forEach(function (impt) {
var key = JSON.stringify(impt.module);
if (deps.indexOf(key) === -1) {
deps.push(key);
setterSources.push('function(m){i[' + key + ']=m}');
}
});
return new Response(new Blob([
'System.register([' + deps.join(',') + '],function(e){var i={};return{setters:[' + setterSources.join(',') +
'],execute:function(){return WebAssembly.instantiate(System.wasmModules[' + JSON.stringify(url) +
'],i).then(function(m){e(m.exports)})}}})'
], {
type: 'application/javascript'
}));
});
return res;
});
};

@@ -870,0 +874,0 @@ })(typeof self !== 'undefined' ? self : global);

/*
* SystemJS 6.6.1
* SystemJS 6.7.0
*/
!function(){function e(e,t){return(t||"")+" (SystemJS Error#"+e+" https://git.io/JvFET#"+e+")"}function t(e,t){if(-1!==e.indexOf("\\")&&(e=e.replace(/\\/g,"/")),"/"===e[0]&&"/"===e[1])return t.slice(0,t.indexOf(":")+1)+e;if("."===e[0]&&("/"===e[1]||"."===e[1]&&("/"===e[2]||2===e.length&&(e+="/"))||1===e.length&&(e+="/"))||"/"===e[0]){var n,r=t.slice(0,t.indexOf(":")+1);if(n="/"===t[r.length+1]?"file:"!==r?(n=t.slice(r.length+2)).slice(n.indexOf("/")+1):t.slice(8):t.slice(r.length+("/"===t[r.length])),"/"===e[0])return t.slice(0,t.length-n.length-1)+e;for(var i=n.slice(0,n.lastIndexOf("/")+1)+e,o=[],u=-1,c=0;i.length>c;c++)-1!==u?"/"===i[c]&&(o.push(i.slice(u,c+1)),u=-1):"."===i[c]?"."!==i[c+1]||"/"!==i[c+2]&&c+2!==i.length?"/"===i[c+1]||c+1===i.length?c+=1:u=c:(o.pop(),c+=2):u=c;return-1!==u&&o.push(i.slice(u)),t.slice(0,t.length-n.length)+o.join("")}}function n(e,n){return t(e,n)||(-1!==e.indexOf(":")?e:t("./"+e,n))}function r(e,n,r,i,o){for(var s in e){var f=t(s,r)||s,a=e[s];if("string"==typeof a){var l=c(i,t(a,r)||a,o);l?n[f]=l:u("W1",s,a,"bare specifier did not resolve")}}}function i(e,t){if(t[e])return e;var n=e.length;do{var r=e.slice(0,n+1);if(r in t)return r}while(-1!==(n=e.lastIndexOf("/",n-1)))}function o(e,t){var n=i(e,t);if(n){var r=t[n];if(null===r)return;if(n.length>=e.length||"/"===r[r.length-1])return r+e.slice(n.length);u("W2",n,r,"should have a trailing '/'")}}function u(t,n,r,i){console.warn(e(t,"Package target "+i+", resolving target '"+r+"' for "+n))}function c(e,t,n){for(var r=e.scopes,u=n&&i(n,r);u;){var c=o(t,r[u]);if(c)return c;u=i(u.slice(0,u.lastIndexOf("/")),r)}return o(t,e.imports)||-1!==t.indexOf(":")&&t}function s(){this[S]={}}function f(e){return e.id}function a(e,t,n,r){if(e.onload(n,t.id,t.d&&t.d.map(f),!!r),n)throw n}function l(t,n,r){var i=t[S][n];if(i)return i;var o=[],u=Object.create(null);x&&Object.defineProperty(u,x,{value:"Module"});var c=Promise.resolve().then((function(){return t.instantiate(n,r)})).then((function(r){if(!r)throw Error(e(2,"Module "+n+" did not instantiate"));var c=r[1]((function(e,t){i.h=!0;var n=!1;if("object"!=typeof e)e in u&&u[e]===t||(u[e]=t,n=!0);else{for(var r in e)t=e[r],r in u&&u[r]===t||(u[r]=t,n=!0);e.__esModule&&(u.__esModule=e.__esModule)}if(n)for(var c=0;o.length>c;c++){var s=o[c];s&&s(u)}return t}),2===r[1].length?{import:function(e){return t.import(e,n)},meta:t.createContext(n)}:void 0);return i.e=c.execute||function(){},[r[0],c.setters||[]]})),s=(c=c.catch((function(e){a(t,i,e,!0)}))).then((function(e){return Promise.all(e[0].map((function(r,i){var o=e[1][i];return Promise.resolve(t.resolve(r,n)).then((function(e){var r=l(t,e,n);return Promise.resolve(r.I).then((function(){return o&&(r.i.push(o),!r.h&&r.I||o(r.n)),r}))}))}))).then((function(e){i.d=e}),(function(e){a(t,i,e,!1)}))}));return s.catch((function(e){i.e=null,i.er=e})),i=t[S][n]={id:n,i:o,n:u,I:c,L:s,h:!1,d:void 0,e:void 0,er:void 0,E:void 0,C:void 0}}function d(){[].forEach.call(document.querySelectorAll("script"),(function(t){if(!t.sp)if("systemjs-module"===t.type){if(t.sp=!0,!t.src)return;System.import("import:"===t.src.slice(0,7)?t.src.slice(7):n(t.src,h))}else if("systemjs-importmap"===t.type){t.sp=!0;var i=t.src?fetch(t.src).then((function(e){return e.text()})):t.innerHTML;C=C.then((function(){return i})).then((function(i){!function(t,i,o){try{var u=JSON.parse(i)}catch(c){throw Error(e(1,"systemjs-importmap contains invalid JSON"))}!function(e,t,i){var o;for(o in e.imports&&r(e.imports,i.imports,t,i,null),e.scopes||{}){var u=n(o,t);r(e.scopes[o],i.scopes[u]||(i.scopes[u]={}),t,i,u)}for(o in e.depcache||{})i.depcache[n(o,t)]=e.depcache[o];for(o in e.integrity||{})i.integrity[n(o,t)]=e.integrity[o]}(u,o,t)}(I,i,t.src||h)}))}}))}var h,v="undefined"!=typeof Symbol,p="undefined"!=typeof self,m="undefined"!=typeof document,g=p?self:global;if(m){var y=document.querySelector("base[href]");y&&(h=y.href)}if(!h&&"undefined"!=typeof location){var b=(h=location.href.split("#")[0].split("?")[0]).lastIndexOf("/");-1!==b&&(h=h.slice(0,b+1))}var E,x=v&&Symbol.toStringTag,S=v?Symbol():"@",O=s.prototype;O.import=function(e,t){var n=this;return Promise.resolve(n.prepareImport()).then((function(){return n.resolve(e,t)})).then((function(e){var t=l(n,e);return t.C||function(e,t){return t.C=function e(t,n,r){if(!r[n.id])return r[n.id]=!0,Promise.resolve(n.L).then((function(){return Promise.all(n.d.map((function(n){return e(t,n,r)})))}))}(e,t,{}).then((function(){return function e(t,n,r){function i(){try{var e=n.e.call(w);if(e)return e=e.then((function(){n.C=n.n,n.E=null,a(t,n,null,!0)}),(function(e){n.er=e,n.E=null,a(t,n,e,!0)})),n.E=n.E||e;n.C=n.n,a(t,n,null,!0)}catch(r){n.er=r,a(t,n,r,!0)}finally{n.L=n.I=void 0,n.e=null}}if(!r[n.id]){if(r[n.id]=!0,!n.e){if(n.er)throw n.er;return n.E?n.E:void 0}var o;return n.d.forEach((function(i){try{var u=e(t,i,r);u&&(o=o||[]).push(u)}catch(c){n.e=null,n.er=c,a(t,n,c,!1)}})),o?Promise.all(o).then(i,(function(e){n.e=null,n.er=e,a(t,n,e,!1)})):i()}}(e,t,{})})).then((function(){return t.n}))}(n,t)}))},O.createContext=function(e){var t=this;return{url:e,resolve:function(n,r){return Promise.resolve(t.resolve(n,r||e))}}},O.onload=function(){},O.register=function(e,t){E=[e,t]},O.getRegister=function(){var e=E;return E=void 0,e};var w=Object.freeze(Object.create(null));g.System=new s;var j,P,C=Promise.resolve(),I={imports:{},scopes:{},depcache:{},integrity:{}},L=m;if(O.prepareImport=function(e){return(L||e)&&(d(),L=!1),C},m&&(d(),window.addEventListener("DOMContentLoaded",d)),m){window.addEventListener("error",(function(e){T=e.filename,W=e.error}));var M=location.origin}O.createScript=function(e){var t=document.createElement("script");t.async=!0,e.indexOf(M+"/")&&(t.crossOrigin="anonymous");var n=I.integrity[e];return n&&(t.integrity=n),t.src=e,t};var T,W,A={},R=O.register;O.register=function(e,t){if(m&&"loading"===document.readyState&&"string"!=typeof e){var n=document.getElementsByTagName("script"),r=n[n.length-1],i=r&&r.src;if(i){j=e;var o=this;P=setTimeout((function(){A[i]=[e,t],o.import(i)}))}}else j=void 0;return R.call(this,e,t)},O.instantiate=function(t,n){var r=A[t];if(r)return delete A[t],r;var i=this;return new Promise((function(r,o){var u=O.createScript(t);u.addEventListener("error",(function(){o(Error(e(3,"Error loading "+t+(n?" from "+n:""))))})),u.addEventListener("load",(function(){if(document.head.removeChild(u),T===t)o(W);else{var e=i.getRegister();e&&e[0]===j&&clearTimeout(P),r(e)}})),document.head.appendChild(u)}))},O.resolve=function(n,r){return c(I,t(n,r=r||h)||n,r)||function(t,n){throw Error(e(8,"Unable to resolve bare specifier '"+t+(n?"' from "+n:"'")))}(n,r)};var _=O.instantiate;O.instantiate=function(e,t){var n=I.depcache[e];if(n)for(var r=0;n.length>r;r++)l(this,this.resolve(n[r],e),e);return _.call(this,e,t)},p&&"function"==typeof importScripts&&(O.instantiate=function(e){var t=this;return Promise.resolve().then((function(){return importScripts(e),t.getRegister()}))}),function(e){function t(t){return!e.hasOwnProperty(t)||!isNaN(t)&&e.length>t||f&&e[t]&&"undefined"!=typeof window&&e[t].parent===window}var n,r,i,o=e.System.constructor.prototype,u=o.import;o.import=function(o,c){return function(){for(var o in n=r=void 0,e)t(o)||(n?r||(r=o):n=o,i=o)}(),u.call(this,o,c)};var c=[[],function(){return{}}],s=o.getRegister;o.getRegister=function(){var o=s.call(this);if(o)return o;var u,f=function(){var o,u=0;for(var c in e)if(!t(c)){if(0===u&&c!==n||1===u&&c!==r)return c;u++,o=c}if(o!==i)return o}();if(!f)return c;try{u=e[f]}catch(a){return c}return[[],function(e){return{execute:function(){e({default:u,__useDefault:!0})}}}]};var f="undefined"!=typeof navigator&&-1!==navigator.userAgent.indexOf("Trident")}("undefined"!=typeof self?self:global),function(t){var n=t.System.constructor.prototype,r=n.instantiate;n.shouldFetch=function(e){var t=e.split("?")[0].split("#")[0];return t.slice(t.lastIndexOf(".")).match(/\.(css|html|json|wasm)$/)},n.fetch=function(e){return fetch(e)},n.instantiate=function(t,n){var i=this;return this.shouldFetch(t)?this.fetch(t).then((function(r){if(!r.ok)throw Error(e(7,r.status+" "+r.statusText+", loading "+t+(n?" from "+n:"")));var o=r.headers.get("content-type");if(!o)throw Error(e(4,'Missing header "Content-Type", loading '+t+(n?" from "+n:"")));if(o.match(/^(text|application)\/(x-)?javascript(;|$)/))return r.text().then((function(e){return(0,eval)(e),i.getRegister()}));if(o.match(/^application\/json(;|$)/))return r.text().then((function(e){return[[],function(t){return{execute:function(){t("default",JSON.parse(e))}}}]}));if(o.match(/^text\/css(;|$)/))return r.text().then((function(e){return[[],function(t){return{execute:function(){var n=new CSSStyleSheet;n.replaceSync(e),t("default",n)}}}]}));if(o.match(/^application\/wasm(;|$)/))return(WebAssembly.compileStreaming?WebAssembly.compileStreaming(r):r.arrayBuffer().then(WebAssembly.compile)).then((function(e){var t=[],n=[],r={};return WebAssembly.Module.imports&&WebAssembly.Module.imports(e).forEach((function(e){var i=e.module;-1===t.indexOf(i)&&(t.push(i),n.push((function(e){r[i]=e})))})),[t,function(t){return{setters:n,execute:function(){return WebAssembly.instantiate(e,r).then((function(e){t(e.exports)}))}}}]}));throw Error(e(4,'Unknown module type "'+o+'"'))})):r.apply(this,arguments)}}("undefined"!=typeof self?self:global);var N="undefined"!=typeof Symbol&&Symbol.toStringTag;O.get=function(e){var t=this[S][e];if(t&&null===t.e&&!t.E)return t.er?null:t.n},O.set=function(t,n){try{new URL(t)}catch(u){console.warn(Error(e("W3",'"'+t+'" is not a valid URL to set in the module registry')))}var r;N&&"Module"===n[N]?r=n:(r=Object.assign(Object.create(null),n),N&&Object.defineProperty(r,N,{value:"Module"}));var i=Promise.resolve(r),o=this[S][t]||(this[S][t]={id:t,i:[],h:!1,d:[],e:null,er:void 0,E:void 0});return!o.e&&!o.E&&(Object.assign(o,{n:r,I:void 0,L:void 0,C:i}),r)},O.has=function(e){return!!this[S][e]},O.delete=function(e){var t=this[S],n=t[e];if(!n||null!==n.e||n.E)return!1;var r=n.i;return n.d&&n.d.forEach((function(e){var t=e.i.indexOf(n);-1!==t&&e.i.splice(t,1)})),delete t[e],function(){var n=t[e];if(!n||!r||null!==n.e||n.E)return!1;r.forEach((function(e){n.i.push(e),e(n.n)})),r=null}};var J="undefined"!=typeof Symbol&&Symbol.iterator;O.entries=function(){var e,t,n=this,r=Object.keys(n[S]),i=0,o={next:function(){for(;void 0!==(t=r[i++])&&void 0===(e=n.get(t)););return{done:void 0===t,value:void 0!==t&&[t,e]}}};return o[J]=function(){return this},o}}();
!function(){function e(e,t){return(t||"")+" (SystemJS Error#"+e+" https://git.io/JvFET#"+e+")"}function t(e,t){if(-1!==e.indexOf("\\")&&(e=e.replace(/\\/g,"/")),"/"===e[0]&&"/"===e[1])return t.slice(0,t.indexOf(":")+1)+e;if("."===e[0]&&("/"===e[1]||"."===e[1]&&("/"===e[2]||2===e.length&&(e+="/"))||1===e.length&&(e+="/"))||"/"===e[0]){var n,r=t.slice(0,t.indexOf(":")+1);if(n="/"===t[r.length+1]?"file:"!==r?(n=t.slice(r.length+2)).slice(n.indexOf("/")+1):t.slice(8):t.slice(r.length+("/"===t[r.length])),"/"===e[0])return t.slice(0,t.length-n.length-1)+e;for(var i=n.slice(0,n.lastIndexOf("/")+1)+e,o=[],s=-1,u=0;i.length>u;u++)-1!==s?"/"===i[u]&&(o.push(i.slice(s,u+1)),s=-1):"."===i[u]?"."!==i[u+1]||"/"!==i[u+2]&&u+2!==i.length?"/"===i[u+1]||u+1===i.length?u+=1:s=u:(o.pop(),u+=2):s=u;return-1!==s&&o.push(i.slice(s)),t.slice(0,t.length-n.length)+o.join("")}}function n(e,n){return t(e,n)||(-1!==e.indexOf(":")?e:t("./"+e,n))}function r(e,n,r,i,o){for(var c in e){var a=t(c,r)||c,f=e[c];if("string"==typeof f){var l=u(i,t(f,r)||f,o);l?n[a]=l:s("W1",c,f,"bare specifier did not resolve")}}}function i(e,t){if(t[e])return e;var n=e.length;do{var r=e.slice(0,n+1);if(r in t)return r}while(-1!==(n=e.lastIndexOf("/",n-1)))}function o(e,t){var n=i(e,t);if(n){var r=t[n];if(null===r)return;if(n.length>=e.length||"/"===r[r.length-1])return r+e.slice(n.length);s("W2",n,r,"should have a trailing '/'")}}function s(t,n,r,i){console.warn(e(t,"Package target "+i+", resolving target '"+r+"' for "+n))}function u(e,t,n){for(var r=e.scopes,s=n&&i(n,r);s;){var u=o(t,r[s]);if(u)return u;s=i(s.slice(0,s.lastIndexOf("/")),r)}return o(t,e.imports)||-1!==t.indexOf(":")&&t}function c(){this[E]={}}function a(e){return e.id}function f(e,t,n,r){if(e.onload(n,t.id,t.d&&t.d.map(a),!!r),n)throw n}function l(t,n,r){var i=t[E][n];if(i)return i;var o=[],s=Object.create(null);w&&Object.defineProperty(s,w,{value:"Module"});var u=Promise.resolve().then((function(){return t.instantiate(n,r)})).then((function(r){if(!r)throw Error(e(2,"Module "+n+" did not instantiate"));var u=r[1]((function(e,t){i.h=!0;var n=!1;if("string"==typeof e)e in s&&s[e]===t||(s[e]=t,n=!0);else{for(var r in e)t=e[r],r in s&&s[r]===t||(s[r]=t,n=!0);e.__esModule&&(s.__esModule=e.__esModule)}if(n)for(var u=0;o.length>u;u++){var c=o[u];c&&c(s)}return t}),2===r[1].length?{import:function(e){return t.import(e,n)},meta:t.createContext(n)}:void 0);return i.e=u.execute||function(){},[r[0],u.setters||[]]})),c=(u=u.catch((function(e){f(t,i,e,!0)}))).then((function(e){return Promise.all(e[0].map((function(r,i){var o=e[1][i];return Promise.resolve(t.resolve(r,n)).then((function(e){var r=l(t,e,n);return Promise.resolve(r.I).then((function(){return o&&(r.i.push(o),!r.h&&r.I||o(r.n)),r}))}))}))).then((function(e){i.d=e}),(function(e){f(t,i,e,!1)}))}));return c.catch((function(e){i.e=null,i.er=e})),i=t[E][n]={id:n,i:o,n:s,I:u,L:c,h:!1,d:void 0,e:void 0,er:void 0,E:void 0,C:void 0}}function d(){[].forEach.call(document.querySelectorAll("script"),(function(t){if(!t.sp)if("systemjs-module"===t.type){if(t.sp=!0,!t.src)return;System.import("import:"===t.src.slice(0,7)?t.src.slice(7):n(t.src,h))}else if("systemjs-importmap"===t.type){t.sp=!0;var i=t.src?fetch(t.src,{integrity:t.integrity}).then((function(e){return e.text()})):t.innerHTML;M=M.then((function(){return i})).then((function(i){!function(t,i,o){try{var s=JSON.parse(i)}catch(u){throw Error(e(1,"systemjs-importmap contains invalid JSON"))}!function(e,t,i){var o;for(o in e.imports&&r(e.imports,i.imports,t,i,null),e.scopes||{}){var s=n(o,t);r(e.scopes[o],i.scopes[s]||(i.scopes[s]={}),t,i,s)}for(o in e.depcache||{})i.depcache[n(o,t)]=e.depcache[o];for(o in e.integrity||{})i.integrity[n(o,t)]=e.integrity[o]}(s,o,t)}(C,i,t.src||h)}))}}))}var h,v="undefined"!=typeof Symbol,p="undefined"!=typeof self,m="undefined"!=typeof document,g=p?self:global;if(m){var y=document.querySelector("base[href]");y&&(h=y.href)}if(!h&&"undefined"!=typeof location){var S=(h=location.href.split("#")[0].split("?")[0]).lastIndexOf("/");-1!==S&&(h=h.slice(0,S+1))}var b,w=v&&Symbol.toStringTag,E=v?Symbol():"@",O=c.prototype;O.import=function(e,t){var n=this;return Promise.resolve(n.prepareImport()).then((function(){return n.resolve(e,t)})).then((function(e){var t=l(n,e);return t.C||function(e,t){return t.C=function e(t,n,r){if(!r[n.id])return r[n.id]=!0,Promise.resolve(n.L).then((function(){return Promise.all(n.d.map((function(n){return e(t,n,r)})))}))}(e,t,{}).then((function(){return function e(t,n,r){function i(){try{var e=n.e.call(x);if(e)return e=e.then((function(){n.C=n.n,n.E=null,f(t,n,null,!0)}),(function(e){n.er=e,n.E=null,f(t,n,e,!0)})),n.E=n.E||e;n.C=n.n,f(t,n,null,!0)}catch(r){n.er=r,f(t,n,r,!0)}finally{n.L=n.I=void 0,n.e=null}}if(!r[n.id]){if(r[n.id]=!0,!n.e){if(n.er)throw n.er;return n.E?n.E:void 0}var o;return n.d.forEach((function(i){try{var s=e(t,i,r);s&&(o=o||[]).push(s)}catch(u){n.e=null,n.er=u,f(t,n,u,!1)}})),o?Promise.all(o).then(i,(function(e){n.e=null,n.er=e,f(t,n,e,!1)})):i()}}(e,t,{})})).then((function(){return t.n}))}(n,t)}))},O.createContext=function(e){var t=this;return{url:e,resolve:function(n,r){return Promise.resolve(t.resolve(n,r||e))}}},O.onload=function(){},O.register=function(e,t){b=[e,t]},O.getRegister=function(){var e=b;return b=void 0,e};var x=Object.freeze(Object.create(null));g.System=new c;var j,P,M=Promise.resolve(),C={imports:{},scopes:{},depcache:{},integrity:{}},L=m;if(O.prepareImport=function(e){return(L||e)&&(d(),L=!1),M},m&&(d(),window.addEventListener("DOMContentLoaded",d)),m){window.addEventListener("error",(function(e){R=e.filename,T=e.error}));var I=location.origin}O.createScript=function(e){var t=document.createElement("script");t.async=!0,e.indexOf(I+"/")&&(t.crossOrigin="anonymous");var n=C.integrity[e];return n&&(t.integrity=n),t.src=e,t};var R,T,N={},W=O.register;O.register=function(e,t){if(m&&"loading"===document.readyState&&"string"!=typeof e){var n=document.getElementsByTagName("script"),r=n[n.length-1],i=r&&r.src;if(i){j=e;var o=this;P=setTimeout((function(){N[i]=[e,t],o.import(i)}))}}else j=void 0;return W.call(this,e,t)},O.instantiate=function(t,n){var r=N[t];if(r)return delete N[t],r;var i=this;return new Promise((function(r,o){var s=O.createScript(t);s.addEventListener("error",(function(){o(Error(e(3,"Error loading "+t+(n?" from "+n:""))))})),s.addEventListener("load",(function(){if(document.head.removeChild(s),R===t)o(T);else{var e=i.getRegister();e&&e[0]===j&&clearTimeout(P),r(e)}})),document.head.appendChild(s)}))},O.shouldFetch=function(){return!1},"undefined"!=typeof fetch&&(O.fetch=fetch);var A=O.instantiate,J=/^(text|application)\/(x-)?javascript(;|$)/;O.instantiate=function(t,n){var r=this;return this.shouldFetch(t)?this.fetch(t,{credentials:"same-origin",integrity:C.integrity[t]}).then((function(i){if(!i.ok)throw Error(e(7,i.status+" "+i.statusText+", loading "+t+(n?" from "+n:"")));var o=i.headers.get("content-type");if(!o||!J.test(o))throw Error(e(4,'Unknown Content-Type "'+o+'", loading '+t+(n?" from "+n:"")));return i.text().then((function(e){return(0,eval)(e),r.getRegister()}))})):A.apply(this,arguments)},O.resolve=function(n,r){return u(C,t(n,r=r||h)||n,r)||function(t,n){throw Error(e(8,"Unable to resolve bare specifier '"+t+(n?"' from "+n:"'")))}(n,r)};var _=O.instantiate;O.instantiate=function(e,t){var n=C.depcache[e];if(n)for(var r=0;n.length>r;r++)l(this,this.resolve(n[r],e),e);return _.call(this,e,t)},p&&"function"==typeof importScripts&&(O.instantiate=function(e){var t=this;return Promise.resolve().then((function(){return importScripts(e),t.getRegister()}))}),function(e){function t(t){return!e.hasOwnProperty(t)||!isNaN(t)&&e.length>t||a&&e[t]&&"undefined"!=typeof window&&e[t].parent===window}var n,r,i,o=e.System.constructor.prototype,s=o.import;o.import=function(o,u){return function(){for(var o in n=r=void 0,e)t(o)||(n?r||(r=o):n=o,i=o)}(),s.call(this,o,u)};var u=[[],function(){return{}}],c=o.getRegister;o.getRegister=function(){var o=c.call(this);if(o)return o;var s,a=function(){var o,s=0;for(var u in e)if(!t(u)){if(0===s&&u!==n||1===s&&u!==r)return u;s++,o=u}if(o!==i)return o}();if(!a)return u;try{s=e[a]}catch(f){return u}return[[],function(e){return{execute:function(){e(s),e({default:s,__useDefault:!0})}}}]};var a="undefined"!=typeof navigator&&-1!==navigator.userAgent.indexOf("Trident")}("undefined"!=typeof self?self:global),function(e){var t=e.System.constructor.prototype,n=/^[^#?]+\.(css|html|json|wasm)([?#].*)?$/;t.shouldFetch=function(e){return n.test(e)};var r=/^application\/json(;|$)/,i=/^text\/css(;|$)/,o=/^application\/wasm(;|$)/,s=t.fetch;t.fetch=function(t,n){return s(t,n).then((function(n){if(!n.ok)return n;var s=n.headers.get("content-type");return r.test(s)?n.json().then((function(e){return new Response(new Blob(['System.register([],function(e){return{execute:function(){e("default",'+JSON.stringify(e)+")}}})"],{type:"application/javascript"}))})):i.test(s)?n.text().then((function(e){return new Response(new Blob(["System.register([],function(e){return{execute:function(){var s=new CSSStyleSheet();s.replaceSync("+JSON.stringify(e)+');e("default",s)}}})'],{type:"application/javascript"}))})):o.test(s)?(WebAssembly.compileStreaming?WebAssembly.compileStreaming(n):n.arrayBuffer().then(WebAssembly.compile)).then((function(n){e.System.wasmModules||(e.System.wasmModules=Object.create(null)),e.System.wasmModules[t]=n;var r=[],i=[];return WebAssembly.Module.imports&&WebAssembly.Module.imports(n).forEach((function(e){var t=JSON.stringify(e.module);-1===r.indexOf(t)&&(r.push(t),i.push("function(m){i["+t+"]=m}"))})),new Response(new Blob(["System.register(["+r.join(",")+"],function(e){var i={};return{setters:["+i.join(",")+"],execute:function(){return WebAssembly.instantiate(System.wasmModules["+JSON.stringify(t)+"],i).then(function(m){e(m.exports)})}}})"],{type:"application/javascript"}))})):n}))}}("undefined"!=typeof self?self:global);var k="undefined"!=typeof Symbol&&Symbol.toStringTag;O.get=function(e){var t=this[E][e];if(t&&null===t.e&&!t.E)return t.er?null:t.n},O.set=function(t,n){try{new URL(t)}catch(s){console.warn(Error(e("W3",'"'+t+'" is not a valid URL to set in the module registry')))}var r;k&&"Module"===n[k]?r=n:(r=Object.assign(Object.create(null),n),k&&Object.defineProperty(r,k,{value:"Module"}));var i=Promise.resolve(r),o=this[E][t]||(this[E][t]={id:t,i:[],h:!1,d:[],e:null,er:void 0,E:void 0});return!o.e&&!o.E&&(Object.assign(o,{n:r,I:void 0,L:void 0,C:i}),r)},O.has=function(e){return!!this[E][e]},O.delete=function(e){var t=this[E],n=t[e];if(!n||null!==n.e||n.E)return!1;var r=n.i;return n.d&&n.d.forEach((function(e){var t=e.i.indexOf(n);-1!==t&&e.i.splice(t,1)})),delete t[e],function(){var n=t[e];if(!n||!r||null!==n.e||n.E)return!1;r.forEach((function(e){n.i.push(e),e(n.n)})),r=null}};var B="undefined"!=typeof Symbol&&Symbol.iterator;O.entries=function(){var e,t,n=this,r=Object.keys(n[E]),i=0,o={next:function(){for(;void 0!==(t=r[i++])&&void 0===(e=n.get(t)););return{done:void 0===t,value:void 0!==t&&[t,e]}}};return o[B]=function(){return this},o}}();
//# sourceMappingURL=system.min.js.map
{
"name": "systemjs",
"version": "6.6.1",
"version": "6.7.0",
"main": "dist/system-node.cjs",

@@ -25,3 +25,3 @@ "exports": {

"devDependencies": {
"@jsenv/file-size-impact": "^5.1.1",
"@jsenv/file-size-impact": "^5.2.0",
"@rollup/plugin-json": "^4.0.2",

@@ -28,0 +28,0 @@ "@rollup/plugin-node-resolve": "^7.1.1",

@@ -8,53 +8,21 @@ # SystemJS

Configurable module loader, running System modules at almost-native speed, and enabling ES module semantics and features such as top-level await, dynamic import, and import maps with full compatibility in older browsers including [IE11](#ie11).
Release Links:
* [Latest 6.x Major Release](https://github.com/systemjs/systemjs/releases/tag/6.0.0)
* [SystemJS 2.0 Announcement Post](https://guybedford.com/systemjs-2.0)
* [SystemJS 0.21](https://github.com/systemjs/systemjs/tree/0.21)
For discussion, join the [Gitter Room](https://gitter.im/systemjs/systemjs).
## Examples
The [systemjs-examples repo](https://github.com/systemjs/systemjs-examples) contains a variety of examples demonstrating how to use SystemJS.
## Performance
SystemJS is designed for production modules performance and can load multiple modules in less than a millisecond. Its performance is only around a factor of 1.5 times the performance of native ES modules, as seen in the following performance benchmark, which was run by loading 426 javascript modules (all of `@babel/core`) on a Macbook pro with fast wifi internet connection. Each test was the average of five page loads in Chrome 80.
| Tool | Uncached | Cached |
| ---- | -------- | ------ |
| Native modules | 1668ms | 49ms |
| SystemJS | 2334ms | 81ms |
| es-module-shims | 2671ms | 602ms |
> [ES module Shims](https://github.com/guybedford/es-module-shims), like SystemJS, provides workflows for import maps and other modules features, but on top of base-level modules support in browsers. The performance difference is because source rewriting happens in browser instead of ahead-of-time like SystemJS handles via the System module format.
## Overview
[Introduction video](https://www.youtube.com/watch?v=AmdKF2UhFzw)
SystemJS is a hookable, standards-based module loader. It provides a workflow where code written for production workflows of native ES modules in browsers ([like Rollup code-splitting builds](https://rollupjs.org/guide/en#code-splitting)), can be transpiled to the [System.register module format](docs/system-register.md) to work in older browsers that don't support native modules, running [almost-native module speeds](#performance) while supporting top-level await, dynamic import, circular references and live bindings, import.meta.url, module types, import maps, integrity and Content Security Policy with compatibility in older browsers back to IE11.
SystemJS provides two hookable base builds:
#### 1. s.js minimal production loader
#### 1. s.js minimal loader
The minimal [2.8KB s.js production loader](dist/s.min.js) includes the following features:
The minimal [2.3KB s.js loader](dist/s.min.js) provides a workflow where code written for production workflows of native ES modules in browsers ([like Rollup code-splitting builds](https://rollupjs.org/guide/en#code-splitting)), can be transpiled to the [System.register module format](docs/system-register.md) to work in older browsers that don't support native modules, including [IE11](#ie11).
* Loads `System.register` modules, the CSP-compatible [SystemJS module format](docs/system-register.md).
* Support for loading bare specifier names with [import maps](docs/import-maps.md) via `<script type="systemjs-importmap">`.
* Supports [hooks](docs/hooks.md) for loader customization.
Since the ES module semantics such as live bindings, circular references, contextual metadata, dynamic import and top-level await [can all be fully supported this way](docs/system-register.md#semantics), while supporting CSP and cross-origin support, this workflow can be relied upon as a polyfill-like path.
* Support for loading [bare specifier names](docs/import-maps.md) through import maps (formerly package maps, formerly map configuration), loaded via `<script type="systemjs-importmap">`.
* Loads and resolves modules as URLs, throwing for bare specifier names (eg `import 'lodash'`) like the native module loader.
* Loads System.register modules.
* Core hookable extensible loader supporting [custom extensions](docs/hooks.md).
#### 2. system.js loader
The [3.7KB system.js loader](dist/system.min.js) loader builds on the s.js core and adds support for [global loading](#extras), [non-javascript module](/docs/module-types.md), and the [SystemJS registry API](/docs/api.md#registry).
The [4.2KB system.js loader](dist/system.min.js) adds the following features in addition to the `s.js` features above:
* Support for loading [bare specifier names](docs/import-maps.md) through import maps (formerly package maps, formerly map configuration), loaded via `<script type="systemjs-importmap">`.
* [Tracing hooks](docs/hooks.md##onloaderr-id-deps-iserrsource-sync) and [registry deletion API](docs/api.md#registry) for reloading workflows.
* Supports loading Wasm, CSS and JSON [module types](docs/module-types.md).
* Includes the [global loading extra](#extras) for loading global scripts, useful for loading library dependencies traditionally loaded with script tags.
* [Tracing hooks](docs/hooks.md#trace-hooks) and [registry deletion API](docs/api.md#registry) for reloading workflows.
* Supports loading Wasm, CSS and JSON [module types](docs/module-types.md).

@@ -65,8 +33,6 @@ #### 3. system-node.cjs loader

* Loading System modules from disk (via `file://` urls).
* Loading System modules from network (via `http://` urls), with included caching that respects the Content-Type header.
* Loading global modules with the included [global loading extra](#extras)
* Supports loading Wasm, CSS and JSON [module types](docs/module-types.md).
* Loading System modules from disk (via `file://` urls) or the network, with included caching that respects the Content-Type header.
* Import Maps (via the `applyImportMap` api).
* [Tracing hooks](docs/hooks.md#trace-hooks) and [registry deletion API](docs/api.md#registry) for reloading workflows.
* Loading global modules with the included [global loading extra](#extras).

@@ -80,5 +46,3 @@ _Loading CommonJS modules is not currently supported in this loader and likely won't be. If you find you need them it is more advisable to use [Node.js native module support](https://nodejs.org/dist/latest/docs/api/esm.html) where possible instead of the SystemJS Node.js loader._

* [AMD loading](dist/extras/amd.js) support (through `Window.define` which is created).
* [Named exports](dist/extras/named-exports.js) convenience extension support for global and AMD module formats (`import { x } from './global.js'` instead of `import G from './global.js'; G.x`)
* [Named register](dist/extras/named-register.js) supports `System.register('name', ...)` named bundles which can then be imported as `System.import('name')` (as well as AMD named define support)
* [Transform loader](dist/extras/transform.js) support, using fetch and eval, supporting a hookable `loader.transform`
* [Dynamic import maps](dist/extras/dynamic-import-maps.js) support. This is currently a _potential_ new standard [feature](https://github.com/guybedford/import-maps-extensions#lazy-loading-of-import-maps).

@@ -93,2 +57,24 @@

## SystemJS Babel
To support easy loading of TypeScript or ES modules in development SystemJS workflows, see the [SystemJS Babel Extension](https://github.com/systemjs/systemjs-babel).
SystemJS does not support direct integration with the native ES module browser loader because there is no way to share dependencies between the module systems. For extending the functionality of the native module loader in browsers, see [ES module Shims](https://github.com/guybedford/es-module-shims), which like SystemJS, provides workflows for import maps and other modules features, but on top of base-level modules support in browsers, which it does using a fast Wasm-based source rewriting to remap module specifiers.
## Performance
SystemJS is designed for production modules performance roughly only around a factor of 1.5 times the speed of native ES modules, as seen in the following performance benchmark, which was run by loading 426 javascript modules (all of `@babel/core`) on a Macbook pro with fast wifi internet connection. Each test was the average of five page loads in Chrome 80.
| Tool | Uncached | Cached |
| ---- | -------- | ------ |
| Native modules | 1668ms | 49ms |
| SystemJS | 2334ms | 81ms |
| es-module-shims | 2671ms | 602ms |
## Getting Started
[Introduction video](https://www.youtube.com/watch?v=AmdKF2UhFzw).
The [systemjs-examples repo](https://github.com/systemjs/systemjs-examples) contains a variety of examples demonstrating how to use SystemJS.
## Backers

@@ -225,9 +211,2 @@

## Loader Extensions
This list can be extended to include third-party loader extensions. [Post a PR](https://github.com/systemjs/systemjs/edit/master/README.md).
* [transform-babel](https://github.com/systemjs/systemjs-transform-babel) Supports ES module transformation into System.register with Babel.
* [systemjs-css-extra](https://github.com/systemjs/systemjs-css-extra) CSS loader plugin
## Compatibility with Webpack

@@ -234,0 +213,0 @@

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc