From 3e2695801d8e6ce95dc56168af97efef415475c5 Mon Sep 17 00:00:00 2001 From: Andrey Vlasov Date: Sat, 29 Feb 2020 09:48:56 +0300 Subject: [PATCH] add new entry --- dist/bootstrap.js | 1105 +++++++++++++++++++++++++++++++++++++++++ dist/bootstrap.js.map | 1 + src/main.js | 7 + webpack.config.js | 24 +- 4 files changed, 1115 insertions(+), 22 deletions(-) create mode 100644 dist/bootstrap.js create mode 100644 dist/bootstrap.js.map create mode 100644 src/main.js diff --git a/dist/bootstrap.js b/dist/bootstrap.js new file mode 100644 index 0000000..af4bae7 --- /dev/null +++ b/dist/bootstrap.js @@ -0,0 +1,1105 @@ +/******/ (function(modules) { // webpackBootstrap +/******/ // The module cache +/******/ var installedModules = {}; +/******/ +/******/ // The require function +/******/ function __webpack_require__(moduleId) { +/******/ +/******/ // Check if module is in cache +/******/ if(installedModules[moduleId]) { +/******/ return installedModules[moduleId].exports; +/******/ } +/******/ // Create a new module (and put it into the cache) +/******/ var module = installedModules[moduleId] = { +/******/ i: moduleId, +/******/ l: false, +/******/ exports: {} +/******/ }; +/******/ +/******/ // Execute the module function +/******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__); +/******/ +/******/ // Flag the module as loaded +/******/ module.l = true; +/******/ +/******/ // Return the exports of the module +/******/ return module.exports; +/******/ } +/******/ +/******/ +/******/ // expose the modules object (__webpack_modules__) +/******/ __webpack_require__.m = modules; +/******/ +/******/ // expose the module cache +/******/ __webpack_require__.c = installedModules; +/******/ +/******/ // define getter function for harmony exports +/******/ __webpack_require__.d = function(exports, name, getter) { +/******/ if(!__webpack_require__.o(exports, name)) { +/******/ Object.defineProperty(exports, name, { enumerable: true, get: getter }); +/******/ } +/******/ }; +/******/ +/******/ // define __esModule on exports +/******/ __webpack_require__.r = function(exports) { +/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { +/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); +/******/ } +/******/ Object.defineProperty(exports, '__esModule', { value: true }); +/******/ }; +/******/ +/******/ // create a fake namespace object +/******/ // mode & 1: value is a module id, require it +/******/ // mode & 2: merge all properties of value into the ns +/******/ // mode & 4: return value when already ns object +/******/ // mode & 8|1: behave like require +/******/ __webpack_require__.t = function(value, mode) { +/******/ if(mode & 1) value = __webpack_require__(value); +/******/ if(mode & 8) return value; +/******/ if((mode & 4) && typeof value === 'object' && value && value.__esModule) return value; +/******/ var ns = Object.create(null); +/******/ __webpack_require__.r(ns); +/******/ Object.defineProperty(ns, 'default', { enumerable: true, value: value }); +/******/ if(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key)); +/******/ return ns; +/******/ }; +/******/ +/******/ // getDefaultExport function for compatibility with non-harmony modules +/******/ __webpack_require__.n = function(module) { +/******/ var getter = module && module.__esModule ? +/******/ function getDefault() { return module['default']; } : +/******/ function getModuleExports() { return module; }; +/******/ __webpack_require__.d(getter, 'a', getter); +/******/ return getter; +/******/ }; +/******/ +/******/ // Object.prototype.hasOwnProperty.call +/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); }; +/******/ +/******/ // __webpack_public_path__ +/******/ __webpack_require__.p = ""; +/******/ +/******/ +/******/ // Load entry module and return exports +/******/ return __webpack_require__(__webpack_require__.s = 0); +/******/ }) +/************************************************************************/ +/******/ ({ + +/***/ "./node_modules/systemjs/dist/system.js": +/*!**********************************************!*\ + !*** ./node_modules/systemjs/dist/system.js ***! + \**********************************************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(global) {/* +* SystemJS 6.2.2 +*/ +(function () { + const hasSelf = typeof self !== 'undefined'; + + const hasDocument = typeof document !== 'undefined'; + + const envGlobal = hasSelf ? self : global; + + let baseUrl; + + if (hasDocument) { + const baseEl = document.querySelector('base[href]'); + if (baseEl) + baseUrl = baseEl.href; + } + + if (!baseUrl && typeof location !== 'undefined') { + baseUrl = location.href.split('#')[0].split('?')[0]; + const lastSepIndex = baseUrl.lastIndexOf('/'); + if (lastSepIndex !== -1) + baseUrl = baseUrl.slice(0, lastSepIndex + 1); + } + + const backslashRegEx = /\\/g; + function resolveIfNotPlainOrUrl (relUrl, parentUrl) { + if (relUrl.indexOf('\\') !== -1) + relUrl = relUrl.replace(backslashRegEx, '/'); + // protocol-relative + if (relUrl[0] === '/' && relUrl[1] === '/') { + return parentUrl.slice(0, parentUrl.indexOf(':') + 1) + relUrl; + } + // relative-url + else if (relUrl[0] === '.' && (relUrl[1] === '/' || relUrl[1] === '.' && (relUrl[2] === '/' || relUrl.length === 2 && (relUrl += '/')) || + relUrl.length === 1 && (relUrl += '/')) || + relUrl[0] === '/') { + const parentProtocol = parentUrl.slice(0, parentUrl.indexOf(':') + 1); + // Disabled, but these cases will give inconsistent results for deep backtracking + //if (parentUrl[parentProtocol.length] !== '/') + // throw Error('Cannot resolve'); + // read pathname from parent URL + // pathname taken to be part after leading "/" + let pathname; + if (parentUrl[parentProtocol.length + 1] === '/') { + // resolving to a :// so we need to read out the auth and host + if (parentProtocol !== 'file:') { + pathname = parentUrl.slice(parentProtocol.length + 2); + pathname = pathname.slice(pathname.indexOf('/') + 1); + } + else { + pathname = parentUrl.slice(8); + } + } + else { + // resolving to :/ so pathname is the /... part + pathname = parentUrl.slice(parentProtocol.length + (parentUrl[parentProtocol.length] === '/')); + } + + if (relUrl[0] === '/') + return parentUrl.slice(0, parentUrl.length - pathname.length - 1) + relUrl; + + // join together and split for removal of .. and . segments + // looping the string instead of anything fancy for perf reasons + // '../../../../../z' resolved to 'x/y' is just 'z' + const segmented = pathname.slice(0, pathname.lastIndexOf('/') + 1) + relUrl; + + const output = []; + let segmentIndex = -1; + for (let i = 0; i < segmented.length; i++) { + // busy reading a segment - only terminate on '/' + if (segmentIndex !== -1) { + if (segmented[i] === '/') { + output.push(segmented.slice(segmentIndex, i + 1)); + segmentIndex = -1; + } + } + + // new segment - check if it is relative + else if (segmented[i] === '.') { + // ../ segment + if (segmented[i + 1] === '.' && (segmented[i + 2] === '/' || i + 2 === segmented.length)) { + output.pop(); + i += 2; + } + // ./ segment + else if (segmented[i + 1] === '/' || i + 1 === segmented.length) { + i += 1; + } + else { + // the start of a new segment as below + segmentIndex = i; + } + } + // it is the start of a new segment + else { + segmentIndex = i; + } + } + // finish reading out the last segment + if (segmentIndex !== -1) + output.push(segmented.slice(segmentIndex)); + return parentUrl.slice(0, parentUrl.length - pathname.length) + output.join(''); + } + } + + /* + * Import maps implementation + * + * To make lookups fast we pre-resolve the entire import map + * and then match based on backtracked hash lookups + * + */ + + function resolveUrl (relUrl, parentUrl) { + return resolveIfNotPlainOrUrl(relUrl, parentUrl) || (relUrl.indexOf(':') !== -1 ? relUrl : resolveIfNotPlainOrUrl('./' + relUrl, parentUrl)); + } + + function objectAssign (to, from) { + for (let p in from) + to[p] = from[p]; + return to; + } + + function resolveAndComposePackages (packages, outPackages, baseUrl, parentMap, parentUrl) { + for (let p in packages) { + const resolvedLhs = resolveIfNotPlainOrUrl(p, baseUrl) || p; + const rhs = packages[p]; + // package fallbacks not currently supported + if (typeof rhs !== 'string') + continue; + const mapped = resolveImportMap(parentMap, resolveIfNotPlainOrUrl(rhs, baseUrl) || rhs, parentUrl); + if (!mapped) + targetWarning(p, rhs, 'bare specifier did not resolve'); + else + outPackages[resolvedLhs] = mapped; + } + } + + function resolveAndComposeImportMap (json, baseUrl, parentMap) { + const outMap = { imports: objectAssign({}, parentMap.imports), scopes: objectAssign({}, parentMap.scopes) }; + + if (json.imports) + resolveAndComposePackages(json.imports, outMap.imports, baseUrl, parentMap, null); + + if (json.scopes) + for (let s in json.scopes) { + const resolvedScope = resolveUrl(s, baseUrl); + resolveAndComposePackages(json.scopes[s], outMap.scopes[resolvedScope] || (outMap.scopes[resolvedScope] = {}), baseUrl, parentMap, resolvedScope); + } + + return outMap; + } + + function getMatch (path, matchObj) { + if (matchObj[path]) + return path; + let sepIndex = path.length; + do { + const segment = path.slice(0, sepIndex + 1); + if (segment in matchObj) + return segment; + } while ((sepIndex = path.lastIndexOf('/', sepIndex - 1)) !== -1) + } + + function applyPackages (id, packages) { + const pkgName = getMatch(id, packages); + if (pkgName) { + const pkg = packages[pkgName]; + if (pkg === null) return; + if (id.length > pkgName.length && pkg[pkg.length - 1] !== '/') + targetWarning(pkgName, pkg, "should have a trailing '/'"); + else + return pkg + id.slice(pkgName.length); + } + } + + function targetWarning (match, target, msg) { + console.warn("Package target " + msg + ", resolving target '" + target + "' for " + match); + } + + function resolveImportMap (importMap, resolvedOrPlain, parentUrl) { + let scopeUrl = parentUrl && getMatch(parentUrl, importMap.scopes); + while (scopeUrl) { + const packageResolution = applyPackages(resolvedOrPlain, importMap.scopes[scopeUrl]); + if (packageResolution) + return packageResolution; + scopeUrl = getMatch(scopeUrl.slice(0, scopeUrl.lastIndexOf('/')), importMap.scopes); + } + return applyPackages(resolvedOrPlain, importMap.imports) || resolvedOrPlain.indexOf(':') !== -1 && resolvedOrPlain; + } + + /* + * SystemJS Core + * + * Provides + * - System.import + * - System.register support for + * live bindings, function hoisting through circular references, + * reexports, dynamic import, import.meta.url, top-level await + * - System.getRegister to get the registration + * - Symbol.toStringTag support in Module objects + * - Hookable System.createContext to customize import.meta + * - System.onload(err, id, deps) handler for tracing / hot-reloading + * + * Core comes with no System.prototype.resolve or + * System.prototype.instantiate implementations + */ + + const hasSymbol = typeof Symbol !== 'undefined'; + const toStringTag = hasSymbol && Symbol.toStringTag; + const REGISTRY = hasSymbol ? Symbol() : '@'; + + function SystemJS () { + this[REGISTRY] = {}; + } + + const systemJSPrototype = SystemJS.prototype; + + systemJSPrototype.prepareImport = function () {}; + + systemJSPrototype.import = function (id, parentUrl) { + const loader = this; + return Promise.resolve(loader.prepareImport()) + .then(function() { + return loader.resolve(id, parentUrl); + }) + .then(function (id) { + const load = getOrCreateLoad(loader, id); + return load.C || topLevelLoad(loader, load); + }); + }; + + // Hookable createContext function -> allowing eg custom import meta + systemJSPrototype.createContext = function (parentId) { + return { + url: parentId + }; + }; + + // onLoad(err, id, deps) provided for tracing / hot-reloading + systemJSPrototype.onload = function () {}; + function loadToId (load) { + return load.id; + } + function triggerOnload (loader, load, err) { + loader.onload(err, load.id, load.d && load.d.map(loadToId)); + if (err) + throw err; + } + + let lastRegister; + systemJSPrototype.register = function (deps, declare) { + lastRegister = [deps, declare]; + }; + + /* + * getRegister provides the last anonymous System.register call + */ + systemJSPrototype.getRegister = function () { + const _lastRegister = lastRegister; + lastRegister = undefined; + return _lastRegister; + }; + + function getOrCreateLoad (loader, id, firstParentUrl) { + let load = loader[REGISTRY][id]; + if (load) + return load; + + const importerSetters = []; + const ns = Object.create(null); + if (toStringTag) + Object.defineProperty(ns, toStringTag, { value: 'Module' }); + + let instantiatePromise = Promise.resolve() + .then(function () { + return loader.instantiate(id, firstParentUrl); + }) + .then(function (registration) { + if (!registration) + throw Error('Module ' + id + ' did not instantiate'); + function _export (name, value) { + // note if we have hoisted exports (including reexports) + load.h = true; + let changed = false; + if (typeof name !== 'object') { + if (!(name in ns) || ns[name] !== value) { + ns[name] = value; + changed = true; + } + } + else { + for (let p in name) { + let value = name[p]; + if (!(p in ns) || ns[p] !== value) { + ns[p] = value; + changed = true; + } + } + + if (name.__esModule) { + ns.__esModule = name.__esModule; + } + } + if (changed) + for (let i = 0; i < importerSetters.length; i++) + importerSetters[i](ns); + return value; + } + const declared = registration[1](_export, registration[1].length === 2 ? { + import: function (importId) { + return loader.import(importId, id); + }, + meta: loader.createContext(id) + } : undefined); + load.e = declared.execute || function () {}; + return [registration[0], declared.setters || []]; + }); + + instantiatePromise = instantiatePromise.catch(function (err) { + triggerOnload(loader, load, err); + }); + + const linkPromise = instantiatePromise + .then(function (instantiation) { + return Promise.all(instantiation[0].map(function (dep, i) { + const setter = instantiation[1][i]; + return Promise.resolve(loader.resolve(dep, id)) + .then(function (depId) { + const depLoad = getOrCreateLoad(loader, depId, id); + // depLoad.I may be undefined for already-evaluated + return Promise.resolve(depLoad.I) + .then(function () { + if (setter) { + depLoad.i.push(setter); + // only run early setters when there are hoisted exports of that module + // the timing works here as pending hoisted export calls will trigger through importerSetters + if (depLoad.h || !depLoad.I) + setter(depLoad.n); + } + return depLoad; + }); + }) + })) + .then(function (depLoads) { + load.d = depLoads; + }); + }); + + linkPromise.catch(function (err) { + load.e = null; + load.er = err; + }); + + // Capital letter = a promise function + return load = loader[REGISTRY][id] = { + id: id, + // importerSetters, the setters functions registered to this dependency + // we retain this to add more later + i: importerSetters, + // module namespace object + n: ns, + + // instantiate + I: instantiatePromise, + // link + L: linkPromise, + // whether it has hoisted exports + h: false, + + // On instantiate completion we have populated: + // dependency load records + d: undefined, + // execution function + // set to NULL immediately after execution (or on any failure) to indicate execution has happened + // in such a case, C should be used, and E, I, L will be emptied + e: undefined, + + // On execution we have populated: + // the execution error if any + er: undefined, + // in the case of TLA, the execution promise + E: undefined, + + // On execution, L, I, E cleared + + // Promise for top-level completion + C: undefined + }; + } + + function instantiateAll (loader, load, loaded) { + if (!loaded[load.id]) { + loaded[load.id] = true; + // load.L may be undefined for already-instantiated + return Promise.resolve(load.L) + .then(function () { + return Promise.all(load.d.map(function (dep) { + return instantiateAll(loader, dep, loaded); + })); + }) + } + } + + function topLevelLoad (loader, load) { + return load.C = instantiateAll(loader, load, {}) + .then(function () { + return postOrderExec(loader, load, {}); + }) + .then(function () { + return load.n; + }); + } + + // the closest we can get to call(undefined) + const nullContext = Object.freeze(Object.create(null)); + + // returns a promise if and only if a top-level await subgraph + // throws on sync errors + function postOrderExec (loader, load, seen) { + if (seen[load.id]) + return; + seen[load.id] = true; + + if (!load.e) { + if (load.er) + throw load.er; + if (load.E) + return load.E; + return; + } + + // deps execute first, unless circular + let depLoadPromises; + load.d.forEach(function (depLoad) { + { + try { + const depLoadPromise = postOrderExec(loader, depLoad, seen); + if (depLoadPromise) { + depLoadPromise.catch(function (err) { + triggerOnload(loader, load, err); + }); + (depLoadPromises = depLoadPromises || []).push(depLoadPromise); + } + } + catch (err) { + triggerOnload(loader, load, err); + } + } + }); + if (depLoadPromises) + return Promise.all(depLoadPromises).then(doExec); + + return doExec(); + + function doExec () { + try { + let execPromise = load.e.call(nullContext); + if (execPromise) { + execPromise = execPromise.then(function () { + load.C = load.n; + load.E = null; // indicates completion + triggerOnload(loader, load, null); + }, function (err) { + triggerOnload(loader, load, err); + }); + return load.E = load.E || execPromise; + } + // (should be a promise, but a minify optimization to leave out Promise.resolve) + load.C = load.n; + triggerOnload(loader, load, null); + } + catch (err) { + triggerOnload(loader, load, err); + load.er = err; + throw err; + } + finally { + load.L = load.I = undefined; + load.e = null; + } + } + } + + envGlobal.System = new SystemJS(); + + /* + * Import map support for SystemJS + * + * + * OR + * + * + * Only those import maps available at the time of SystemJS initialization will be loaded + * and they will be loaded in DOM order. + * + * There is no support for dynamic import maps injection currently. + */ + + let importMap = { imports: {}, scopes: {} }, importMapPromise; + + if (hasDocument) { + Array.prototype.forEach.call(document.querySelectorAll('script[type="systemjs-importmap"][src]'), function (script) { + script._j = fetch(script.src).then(function (res) { + return res.json(); + }); + }); + } + + systemJSPrototype.prepareImport = function () { + if (!importMapPromise) { + importMapPromise = Promise.resolve(); + if (hasDocument) + Array.prototype.forEach.call(document.querySelectorAll('script[type="systemjs-importmap"]'), function (script) { + importMapPromise = importMapPromise.then(function () { + return (script._j || script.src && fetch(script.src).then(function (resp) { return resp.json(); }) || Promise.resolve(JSON.parse(script.innerHTML))) + .then(function (json) { + importMap = resolveAndComposeImportMap(json, script.src || baseUrl, importMap); + }); + }); + }); + } + return importMapPromise; + }; + + systemJSPrototype.resolve = function (id, parentUrl) { + parentUrl = parentUrl || baseUrl; + return resolveImportMap(importMap, resolveIfNotPlainOrUrl(id, parentUrl) || id, parentUrl) || throwUnresolved(id, parentUrl); + }; + + function throwUnresolved (id, parentUrl) { + throw Error("Unable to resolve specifier '" + id + (parentUrl ? "' from " + parentUrl : "'")); + } + + /* + * Supports loading System.register via script tag injection + */ + + const systemRegister = systemJSPrototype.register; + systemJSPrototype.register = function (deps, declare) { + systemRegister.call(this, deps, declare); + }; + + systemJSPrototype.createScript = function (url) { + const script = document.createElement('script'); + script.charset = 'utf-8'; + script.async = true; + script.crossOrigin = 'anonymous'; + script.src = url; + return script; + }; + + let lastWindowErrorUrl, lastWindowError; + if (hasDocument) + window.addEventListener('error', function (evt) { + lastWindowErrorUrl = evt.filename; + lastWindowError = evt.error; + }); + + systemJSPrototype.instantiate = function (url, firstParentUrl) { + const loader = this; + return new Promise(function (resolve, reject) { + const script = systemJSPrototype.createScript(url); + script.addEventListener('error', function () { + reject(Error('Error loading ' + url + (firstParentUrl ? ' from ' + firstParentUrl : ''))); + }); + script.addEventListener('load', function () { + document.head.removeChild(script); + // Note that if an error occurs that isn't caught by this if statement, + // that getRegister will return null and a "did not instantiate" error will be thrown. + if (lastWindowErrorUrl === url) { + reject(lastWindowError); + } + else { + resolve(loader.getRegister()); + } + }); + document.head.appendChild(script); + }); + }; + + if (hasDocument) { + window.addEventListener('DOMContentLoaded', loadScriptModules); + loadScriptModules(); + } + + function loadScriptModules() { + Array.prototype.forEach.call( + document.querySelectorAll('script[type=systemjs-module]'), function (script) { + if (script.src) { + System.import(script.src.slice(0, 7) === 'import:' ? script.src.slice(7) : resolveUrl(script.src, baseUrl)); + } + }); + } + + /* + * Supports loading System.register in workers + */ + + if (hasSelf && typeof importScripts === 'function') + systemJSPrototype.instantiate = function (url) { + const loader = this; + return new Promise(function (resolve, reject) { + try { + importScripts(url); + } + catch (e) { + reject(e); + } + resolve(loader.getRegister()); + }); + }; + + /* + * SystemJS global script loading support + * Extra for the s.js build only + * (Included by default in system.js build) + */ + (function (global) { + const systemJSPrototype = global.System.constructor.prototype; + const isIE = navigator.userAgent.indexOf('Trident') !== -1; + + // safari unpredictably lists some new globals first or second in object order + let firstGlobalProp, secondGlobalProp, lastGlobalProp; + function getGlobalProp () { + let cnt = 0; + let lastProp; + for (let p in global) { + // do not check frames cause it could be removed during import + if ( + !global.hasOwnProperty(p) + || (!isNaN(p) && p < global.length) + || (isIE && global[p] && global[p].parent === window) + ) + continue; + if (cnt === 0 && p !== firstGlobalProp || cnt === 1 && p !== secondGlobalProp) + return p; + cnt++; + lastProp = p; + } + if (lastProp !== lastGlobalProp) + return lastProp; + } + + function noteGlobalProps () { + // alternatively Object.keys(global).pop() + // but this may be faster (pending benchmarks) + firstGlobalProp = secondGlobalProp = undefined; + for (let p in global) { + // do not check frames cause it could be removed during import + if ( + !global.hasOwnProperty(p) + || (!isNaN(p) && p < global.length) + || (isIE && global[p] && global[p].parent === window) + ) + continue; + if (!firstGlobalProp) + firstGlobalProp = p; + else if (!secondGlobalProp) + secondGlobalProp = p; + lastGlobalProp = p; + } + return lastGlobalProp; + } + + const impt = systemJSPrototype.import; + systemJSPrototype.import = function (id, parentUrl) { + noteGlobalProps(); + return impt.call(this, id, parentUrl); + }; + + const emptyInstantiation = [[], function () { return {} }]; + + const getRegister = systemJSPrototype.getRegister; + systemJSPrototype.getRegister = function () { + const lastRegister = getRegister.call(this); + if (lastRegister) + return lastRegister; + + // no registration -> attempt a global detection as difference from snapshot + // when multiple globals, we take the global value to be the last defined new global object property + // for performance, this will not support multi-version / global collisions as previous SystemJS versions did + // note in Edge, deleting and re-adding a global does not change its ordering + const globalProp = getGlobalProp(); + if (!globalProp) + return emptyInstantiation; + + let globalExport; + try { + globalExport = global[globalProp]; + } + catch (e) { + return emptyInstantiation; + } + + return [[], function (_export) { + return { + execute: function () { + _export({ default: globalExport, __useDefault: true }); + } + }; + }]; + }; + })(typeof self !== 'undefined' ? self : global); + + /* + * Loads JSON, CSS, Wasm module types based on file extensions + * Supports application/javascript falling back to JS eval + */ + (function(global) { + const systemJSPrototype = global.System.constructor.prototype; + const instantiate = systemJSPrototype.instantiate; + + const moduleTypesRegEx = /\.(css|html|json|wasm)$/; + systemJSPrototype.shouldFetch = function (url) { + const path = url.split('?')[0].split('#')[0]; + const ext = path.slice(path.lastIndexOf('.')); + return ext.match(moduleTypesRegEx); + }; + systemJSPrototype.fetch = function (url) { + return fetch(url); + }; + + systemJSPrototype.instantiate = function (url, parent) { + const loader = this; + if (this.shouldFetch(url)) { + return this.fetch(url) + .then(function (res) { + if (!res.ok) + throw Error(res.status + ' ' + res.statusText + ', loading ' + url + (parent ? ' from ' + parent : '')); + const contentType = res.headers.get('content-type'); + 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 + const 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) { + const deps = []; + const setters = []; + const importObj = {}; + + // we can only set imports if supported (eg early Safari doesnt support) + if (WebAssembly.Module.imports) + WebAssembly.Module.imports(module).forEach(function (impt) { + const 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 new Error('Unknown module type "' + contentType + '"'); + } + }); + } + return instantiate.apply(this, arguments); + }; + })(typeof self !== 'undefined' ? self : global); + + const toStringTag$1 = typeof Symbol !== 'undefined' && Symbol.toStringTag; + + systemJSPrototype.get = function (id) { + const load = this[REGISTRY][id]; + if (load && load.e === null && !load.E) { + if (load.er) + return null; + return load.n; + } + }; + + systemJSPrototype.set = function (id, module) { + let ns; + if (toStringTag$1 && module[toStringTag$1] === 'Module') { + ns = module; + } + else { + ns = Object.assign(Object.create(null), module); + if (toStringTag$1) + Object.defineProperty(ns, toStringTag$1, { value: 'Module' }); + } + + const done = Promise.resolve(ns); + + const load = this[REGISTRY][id] || (this[REGISTRY][id] = { + id: id, + i: [], + h: false, + d: [], + e: null, + er: undefined, + E: undefined + }); + + if (load.e || load.E) + return false; + + Object.assign(load, { + n: ns, + I: undefined, + L: undefined, + C: done + }); + return ns; + }; + + systemJSPrototype.has = function (id) { + const load = this[REGISTRY][id]; + return !!load; + }; + + // Delete function provided for hot-reloading use cases + systemJSPrototype.delete = function (id) { + const registry = this[REGISTRY]; + const load = registry[id]; + // in future we can support load.E case by failing load first + // but that will require TLA callbacks to be implemented + if (!load || load.e !== null || load.E) + return false; + + let importerSetters = load.i; + // remove from importerSetters + // (release for gc) + if (load.d) + load.d.forEach(function (depLoad) { + const importerIndex = depLoad.i.indexOf(load); + if (importerIndex !== -1) + depLoad.i.splice(importerIndex, 1); + }); + delete registry[id]; + return function () { + const load = registry[id]; + if (!load || !importerSetters || load.e !== null || load.E) + return false; + // add back the old setters + importerSetters.forEach(function (setter) { + load.i.push(setter); + setter(load.n); + }); + importerSetters = null; + }; + }; + + const iterator = typeof Symbol !== 'undefined' && Symbol.iterator; + + systemJSPrototype.entries = function () { + const loader = this, keys = Object.keys(loader[REGISTRY]); + let index = 0, ns, key; + const result = { + next: function () { + while ( + (key = keys[index++]) !== undefined && + (ns = loader.get(key)) === undefined + ); + return { + done: key === undefined, + value: key !== undefined && [key, ns] + }; + } + }; + + result[iterator] = function() { return this }; + + return result; + }; + +}()); + +/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(/*! ./../../webpack/buildin/global.js */ "./node_modules/webpack/buildin/global.js"))) + +/***/ }), + +/***/ "./node_modules/webpack/buildin/global.js": +/*!***********************************!*\ + !*** (webpack)/buildin/global.js ***! + \***********************************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +var g; + +// This works in non-strict mode +g = (function() { + return this; +})(); + +try { + // This works if eval is allowed (see CSP) + g = g || new Function("return this")(); +} catch (e) { + // This works if the window reference is available + if (true) g = window; +} + +// g can still be undefined, but nothing to do about it... +// We return undefined, instead of nothing here, so it's +// easier to handle this case. if(!global) { ...} + +module.exports = g; + + +/***/ }), + +/***/ "./node_modules/webpack/buildin/module.js": +/*!***********************************!*\ + !*** (webpack)/buildin/module.js ***! + \***********************************/ +/*! no static exports found */ +/***/ (function(module, exports) { + +module.exports = function(module) { + if (!module.webpackPolyfill) { + module.deprecate = function() {}; + module.paths = []; + // module.parent = undefined by default + if (!module.children) module.children = []; + Object.defineProperty(module, "loaded", { + enumerable: true, + get: function() { + return module.l; + } + }); + Object.defineProperty(module, "id", { + enumerable: true, + get: function() { + return module.i; + } + }); + module.webpackPolyfill = 1; + } + return module; +}; + + +/***/ }), + +/***/ "./src/main.js": +/*!*********************!*\ + !*** ./src/main.js ***! + \*********************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(module) {const sysytemJs = __webpack_require__(/*! systemjs/dist/system */ "./node_modules/systemjs/dist/system.js") + +module.export = ({ apps, navigations, config }) => { + sysytemJs.import('./main/index.js') +}; +/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(/*! ./../node_modules/webpack/buildin/module.js */ "./node_modules/webpack/buildin/module.js")(module))) + +/***/ }), + +/***/ 0: +/*!***************************!*\ + !*** multi ./src/main.js ***! + \***************************/ +/*! no static exports found */ +/***/ (function(module, exports, __webpack_require__) { + +module.exports = __webpack_require__(/*! ./src/main.js */"./src/main.js"); + + +/***/ }) + +/******/ }); +//# sourceMappingURL=bootstrap.js.map \ No newline at end of file diff --git a/dist/bootstrap.js.map b/dist/bootstrap.js.map new file mode 100644 index 0000000..eeeb566 --- /dev/null +++ b/dist/bootstrap.js.map @@ -0,0 +1 @@ +{"version":3,"sources":["webpack:///webpack/bootstrap","webpack:///./node_modules/systemjs/dist/system.js","webpack:///(webpack)/buildin/global.js","webpack:///(webpack)/buildin/module.js","webpack:///./src/main.js"],"names":[],"mappings":";QAAA;QACA;;QAEA;QACA;;QAEA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;;QAEA;QACA;;QAEA;QACA;;QAEA;QACA;QACA;;;QAGA;QACA;;QAEA;QACA;;QAEA;QACA;QACA;QACA,0CAA0C,gCAAgC;QAC1E;QACA;;QAEA;QACA;QACA;QACA,wDAAwD,kBAAkB;QAC1E;QACA,iDAAiD,cAAc;QAC/D;;QAEA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA,yCAAyC,iCAAiC;QAC1E,gHAAgH,mBAAmB,EAAE;QACrI;QACA;;QAEA;QACA;QACA;QACA,2BAA2B,0BAA0B,EAAE;QACvD,iCAAiC,eAAe;QAChD;QACA;QACA;;QAEA;QACA,sDAAsD,+DAA+D;;QAErH;QACA;;;QAGA;QACA;;;;;;;;;;;;AClFA;AACA;AACA;AACA;AACA;;AAEA;;AAEA;;AAEA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA,qBAAqB,sBAAsB;AAC3C;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA,oBAAoB,yBAAyB,6CAA6C;;AAE1F;AACA;;AAEA;AACA;AACA;AACA,oHAAoH;AACpH;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;;AAEA;;AAEA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA,KAAK;AACL;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA,8CAA8C,kBAAkB;;AAEhE;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA,yBAAyB,4BAA4B;AACrD;AACA;AACA;AACA;AACA;AACA;AACA,SAAS;AACT;AACA,OAAO;AACP;AACA;AACA,KAAK;;AAEL;AACA;AACA,OAAO;;AAEP;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,WAAW;AACX,SAAS;AACT,OAAO;AACP;AACA;AACA,OAAO;AACP,KAAK;;AAEL;AACA;AACA;AACA,KAAK;;AAEL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,SAAS;AACT,OAAO;AACP;AACA;;AAEA;AACA,mDAAmD;AACnD;AACA,2CAA2C;AAC3C,KAAK;AACL;AACA;AACA,KAAK;AACL;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,aAAa;AACb;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;;AAEA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA,4BAA4B;AAC5B;AACA,aAAa;AACb;AACA,aAAa;AACb;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;;AAEA;AACA;AACA;AACA,yCAAyC;AACzC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,mBAAmB,YAAY,YAAY,EAAE;;AAE7C;AACA;AACA;AACA;AACA,OAAO;AACP,KAAK;AACL;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA,uFAAuF,oBAAoB,EAAE;AAC7G;AACA;AACA,aAAa;AACb,WAAW;AACX,SAAS;AACT;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA,KAAK;;AAEL;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP;AACA,KAAK;AACL;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA,iDAAiD,UAAU,EAAE;;AAE7D;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA,qBAAqB,4CAA4C;AACjE;AACA;AACA,OAAO;AACP;AACA,GAAG;;AAEH;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,uEAAuE;AACvE;AACA;AACA;AACA,aAAa;AACb;AACA,0DAA0D;AAC1D;AACA;AACA;AACA;AACA;AACA;AACA;AACA,eAAe;AACf,aAAa;AACb;AACA,kDAAkD;AAClD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,eAAe;AACf,aAAa,E;AACb;AACA,0DAA0D;AAC1D;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,qBAAqB;AACrB;AACA,iBAAiB;;AAEjB;AACA;AACA;AACA;AACA;AACA;AACA;AACA,qBAAqB;AACrB;AACA;AACA,eAAe;AACf,aAAa;AACb;AACA;AACA;AACA;AACA,SAAS;AACT;AACA;AACA;AACA,GAAG;;AAEH;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,kDAAkD,kBAAkB;AACpE;;AAEA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;;AAEL;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP;AACA;AACA;;AAEA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,mCAAmC;;AAEnC;AACA;;AAEA,CAAC;;;;;;;;;;;;;AC94BD;;AAEA;AACA;AACA;AACA,CAAC;;AAED;AACA;AACA;AACA,CAAC;AACD;AACA,KAAK,IAA0B;AAC/B;;AAEA;AACA;AACA,4CAA4C;;AAE5C;;;;;;;;;;;;ACnBA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;AACA;;;;;;;;;;;;ACrBA,gEAAkB,mBAAO,CAAC,oEAAsB;;AAEhD,kBAAkB,4BAA4B;AAC9C;AACA,E","file":"bootstrap.js","sourcesContent":[" \t// The module cache\n \tvar installedModules = {};\n\n \t// The require function\n \tfunction __webpack_require__(moduleId) {\n\n \t\t// Check if module is in cache\n \t\tif(installedModules[moduleId]) {\n \t\t\treturn installedModules[moduleId].exports;\n \t\t}\n \t\t// Create a new module (and put it into the cache)\n \t\tvar module = installedModules[moduleId] = {\n \t\t\ti: moduleId,\n \t\t\tl: false,\n \t\t\texports: {}\n \t\t};\n\n \t\t// Execute the module function\n \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n \t\t// Flag the module as loaded\n \t\tmodule.l = true;\n\n \t\t// Return the exports of the module\n \t\treturn module.exports;\n \t}\n\n\n \t// expose the modules object (__webpack_modules__)\n \t__webpack_require__.m = modules;\n\n \t// expose the module cache\n \t__webpack_require__.c = installedModules;\n\n \t// define getter function for harmony exports\n \t__webpack_require__.d = function(exports, name, getter) {\n \t\tif(!__webpack_require__.o(exports, name)) {\n \t\t\tObject.defineProperty(exports, name, { enumerable: true, get: getter });\n \t\t}\n \t};\n\n \t// define __esModule on exports\n \t__webpack_require__.r = function(exports) {\n \t\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n \t\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n \t\t}\n \t\tObject.defineProperty(exports, '__esModule', { value: true });\n \t};\n\n \t// create a fake namespace object\n \t// mode & 1: value is a module id, require it\n \t// mode & 2: merge all properties of value into the ns\n \t// mode & 4: return value when already ns object\n \t// mode & 8|1: behave like require\n \t__webpack_require__.t = function(value, mode) {\n \t\tif(mode & 1) value = __webpack_require__(value);\n \t\tif(mode & 8) return value;\n \t\tif((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;\n \t\tvar ns = Object.create(null);\n \t\t__webpack_require__.r(ns);\n \t\tObject.defineProperty(ns, 'default', { enumerable: true, value: value });\n \t\tif(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));\n \t\treturn ns;\n \t};\n\n \t// getDefaultExport function for compatibility with non-harmony modules\n \t__webpack_require__.n = function(module) {\n \t\tvar getter = module && module.__esModule ?\n \t\t\tfunction getDefault() { return module['default']; } :\n \t\t\tfunction getModuleExports() { return module; };\n \t\t__webpack_require__.d(getter, 'a', getter);\n \t\treturn getter;\n \t};\n\n \t// Object.prototype.hasOwnProperty.call\n \t__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };\n\n \t// __webpack_public_path__\n \t__webpack_require__.p = \"\";\n\n\n \t// Load entry module and return exports\n \treturn __webpack_require__(__webpack_require__.s = 0);\n","/*\n* SystemJS 6.2.2\n*/\n(function () {\n const hasSelf = typeof self !== 'undefined';\n\n const hasDocument = typeof document !== 'undefined';\n\n const envGlobal = hasSelf ? self : global;\n\n let baseUrl;\n\n if (hasDocument) {\n const baseEl = document.querySelector('base[href]');\n if (baseEl)\n baseUrl = baseEl.href;\n }\n\n if (!baseUrl && typeof location !== 'undefined') {\n baseUrl = location.href.split('#')[0].split('?')[0];\n const lastSepIndex = baseUrl.lastIndexOf('/');\n if (lastSepIndex !== -1)\n baseUrl = baseUrl.slice(0, lastSepIndex + 1);\n }\n\n const backslashRegEx = /\\\\/g;\n function resolveIfNotPlainOrUrl (relUrl, parentUrl) {\n if (relUrl.indexOf('\\\\') !== -1)\n relUrl = relUrl.replace(backslashRegEx, '/');\n // protocol-relative\n if (relUrl[0] === '/' && relUrl[1] === '/') {\n return parentUrl.slice(0, parentUrl.indexOf(':') + 1) + relUrl;\n }\n // relative-url\n else if (relUrl[0] === '.' && (relUrl[1] === '/' || relUrl[1] === '.' && (relUrl[2] === '/' || relUrl.length === 2 && (relUrl += '/')) ||\n relUrl.length === 1 && (relUrl += '/')) ||\n relUrl[0] === '/') {\n const parentProtocol = parentUrl.slice(0, parentUrl.indexOf(':') + 1);\n // Disabled, but these cases will give inconsistent results for deep backtracking\n //if (parentUrl[parentProtocol.length] !== '/')\n // throw Error('Cannot resolve');\n // read pathname from parent URL\n // pathname taken to be part after leading \"/\"\n let pathname;\n if (parentUrl[parentProtocol.length + 1] === '/') {\n // resolving to a :// so we need to read out the auth and host\n if (parentProtocol !== 'file:') {\n pathname = parentUrl.slice(parentProtocol.length + 2);\n pathname = pathname.slice(pathname.indexOf('/') + 1);\n }\n else {\n pathname = parentUrl.slice(8);\n }\n }\n else {\n // resolving to :/ so pathname is the /... part\n pathname = parentUrl.slice(parentProtocol.length + (parentUrl[parentProtocol.length] === '/'));\n }\n\n if (relUrl[0] === '/')\n return parentUrl.slice(0, parentUrl.length - pathname.length - 1) + relUrl;\n\n // join together and split for removal of .. and . segments\n // looping the string instead of anything fancy for perf reasons\n // '../../../../../z' resolved to 'x/y' is just 'z'\n const segmented = pathname.slice(0, pathname.lastIndexOf('/') + 1) + relUrl;\n\n const output = [];\n let segmentIndex = -1;\n for (let i = 0; i < segmented.length; i++) {\n // busy reading a segment - only terminate on '/'\n if (segmentIndex !== -1) {\n if (segmented[i] === '/') {\n output.push(segmented.slice(segmentIndex, i + 1));\n segmentIndex = -1;\n }\n }\n\n // new segment - check if it is relative\n else if (segmented[i] === '.') {\n // ../ segment\n if (segmented[i + 1] === '.' && (segmented[i + 2] === '/' || i + 2 === segmented.length)) {\n output.pop();\n i += 2;\n }\n // ./ segment\n else if (segmented[i + 1] === '/' || i + 1 === segmented.length) {\n i += 1;\n }\n else {\n // the start of a new segment as below\n segmentIndex = i;\n }\n }\n // it is the start of a new segment\n else {\n segmentIndex = i;\n }\n }\n // finish reading out the last segment\n if (segmentIndex !== -1)\n output.push(segmented.slice(segmentIndex));\n return parentUrl.slice(0, parentUrl.length - pathname.length) + output.join('');\n }\n }\n\n /*\n * Import maps implementation\n *\n * To make lookups fast we pre-resolve the entire import map\n * and then match based on backtracked hash lookups\n *\n */\n\n function resolveUrl (relUrl, parentUrl) {\n return resolveIfNotPlainOrUrl(relUrl, parentUrl) || (relUrl.indexOf(':') !== -1 ? relUrl : resolveIfNotPlainOrUrl('./' + relUrl, parentUrl));\n }\n\n function objectAssign (to, from) {\n for (let p in from)\n to[p] = from[p];\n return to;\n }\n\n function resolveAndComposePackages (packages, outPackages, baseUrl, parentMap, parentUrl) {\n for (let p in packages) {\n const resolvedLhs = resolveIfNotPlainOrUrl(p, baseUrl) || p;\n const rhs = packages[p];\n // package fallbacks not currently supported\n if (typeof rhs !== 'string')\n continue;\n const mapped = resolveImportMap(parentMap, resolveIfNotPlainOrUrl(rhs, baseUrl) || rhs, parentUrl);\n if (!mapped)\n targetWarning(p, rhs, 'bare specifier did not resolve');\n else\n outPackages[resolvedLhs] = mapped;\n }\n }\n\n function resolveAndComposeImportMap (json, baseUrl, parentMap) {\n const outMap = { imports: objectAssign({}, parentMap.imports), scopes: objectAssign({}, parentMap.scopes) };\n\n if (json.imports)\n resolveAndComposePackages(json.imports, outMap.imports, baseUrl, parentMap, null);\n\n if (json.scopes)\n for (let s in json.scopes) {\n const resolvedScope = resolveUrl(s, baseUrl);\n resolveAndComposePackages(json.scopes[s], outMap.scopes[resolvedScope] || (outMap.scopes[resolvedScope] = {}), baseUrl, parentMap, resolvedScope);\n }\n\n return outMap;\n }\n\n function getMatch (path, matchObj) {\n if (matchObj[path])\n return path;\n let sepIndex = path.length;\n do {\n const segment = path.slice(0, sepIndex + 1);\n if (segment in matchObj)\n return segment;\n } while ((sepIndex = path.lastIndexOf('/', sepIndex - 1)) !== -1)\n }\n\n function applyPackages (id, packages) {\n const pkgName = getMatch(id, packages);\n if (pkgName) {\n const pkg = packages[pkgName];\n if (pkg === null) return;\n if (id.length > pkgName.length && pkg[pkg.length - 1] !== '/')\n targetWarning(pkgName, pkg, \"should have a trailing '/'\");\n else\n return pkg + id.slice(pkgName.length);\n }\n }\n\n function targetWarning (match, target, msg) {\n console.warn(\"Package target \" + msg + \", resolving target '\" + target + \"' for \" + match);\n }\n\n function resolveImportMap (importMap, resolvedOrPlain, parentUrl) {\n let scopeUrl = parentUrl && getMatch(parentUrl, importMap.scopes);\n while (scopeUrl) {\n const packageResolution = applyPackages(resolvedOrPlain, importMap.scopes[scopeUrl]);\n if (packageResolution)\n return packageResolution;\n scopeUrl = getMatch(scopeUrl.slice(0, scopeUrl.lastIndexOf('/')), importMap.scopes);\n }\n return applyPackages(resolvedOrPlain, importMap.imports) || resolvedOrPlain.indexOf(':') !== -1 && resolvedOrPlain;\n }\n\n /*\n * SystemJS Core\n * \n * Provides\n * - System.import\n * - System.register support for\n * live bindings, function hoisting through circular references,\n * reexports, dynamic import, import.meta.url, top-level await\n * - System.getRegister to get the registration\n * - Symbol.toStringTag support in Module objects\n * - Hookable System.createContext to customize import.meta\n * - System.onload(err, id, deps) handler for tracing / hot-reloading\n * \n * Core comes with no System.prototype.resolve or\n * System.prototype.instantiate implementations\n */\n\n const hasSymbol = typeof Symbol !== 'undefined';\n const toStringTag = hasSymbol && Symbol.toStringTag;\n const REGISTRY = hasSymbol ? Symbol() : '@';\n\n function SystemJS () {\n this[REGISTRY] = {};\n }\n\n const systemJSPrototype = SystemJS.prototype;\n\n systemJSPrototype.prepareImport = function () {};\n\n systemJSPrototype.import = function (id, parentUrl) {\n const loader = this;\n return Promise.resolve(loader.prepareImport())\n .then(function() {\n return loader.resolve(id, parentUrl);\n })\n .then(function (id) {\n const load = getOrCreateLoad(loader, id);\n return load.C || topLevelLoad(loader, load);\n });\n };\n\n // Hookable createContext function -> allowing eg custom import meta\n systemJSPrototype.createContext = function (parentId) {\n return {\n url: parentId\n };\n };\n\n // onLoad(err, id, deps) provided for tracing / hot-reloading\n systemJSPrototype.onload = function () {};\n function loadToId (load) {\n return load.id;\n }\n function triggerOnload (loader, load, err) {\n loader.onload(err, load.id, load.d && load.d.map(loadToId));\n if (err)\n throw err;\n }\n\n let lastRegister;\n systemJSPrototype.register = function (deps, declare) {\n lastRegister = [deps, declare];\n };\n\n /*\n * getRegister provides the last anonymous System.register call\n */\n systemJSPrototype.getRegister = function () {\n const _lastRegister = lastRegister;\n lastRegister = undefined;\n return _lastRegister;\n };\n\n function getOrCreateLoad (loader, id, firstParentUrl) {\n let load = loader[REGISTRY][id];\n if (load)\n return load;\n\n const importerSetters = [];\n const ns = Object.create(null);\n if (toStringTag)\n Object.defineProperty(ns, toStringTag, { value: 'Module' });\n \n let instantiatePromise = Promise.resolve()\n .then(function () {\n return loader.instantiate(id, firstParentUrl);\n })\n .then(function (registration) {\n if (!registration)\n throw Error('Module ' + id + ' did not instantiate');\n function _export (name, value) {\n // note if we have hoisted exports (including reexports)\n load.h = true;\n let changed = false;\n if (typeof name !== 'object') {\n if (!(name in ns) || ns[name] !== value) {\n ns[name] = value;\n changed = true;\n }\n }\n else {\n for (let p in name) {\n let value = name[p];\n if (!(p in ns) || ns[p] !== value) {\n ns[p] = value;\n changed = true;\n }\n }\n\n if (name.__esModule) {\n ns.__esModule = name.__esModule;\n }\n }\n if (changed)\n for (let i = 0; i < importerSetters.length; i++)\n importerSetters[i](ns);\n return value;\n }\n const declared = registration[1](_export, registration[1].length === 2 ? {\n import: function (importId) {\n return loader.import(importId, id);\n },\n meta: loader.createContext(id)\n } : undefined);\n load.e = declared.execute || function () {};\n return [registration[0], declared.setters || []];\n });\n\n instantiatePromise = instantiatePromise.catch(function (err) {\n triggerOnload(loader, load, err);\n });\n\n const linkPromise = instantiatePromise\n .then(function (instantiation) {\n return Promise.all(instantiation[0].map(function (dep, i) {\n const setter = instantiation[1][i];\n return Promise.resolve(loader.resolve(dep, id))\n .then(function (depId) {\n const depLoad = getOrCreateLoad(loader, depId, id);\n // depLoad.I may be undefined for already-evaluated\n return Promise.resolve(depLoad.I)\n .then(function () {\n if (setter) {\n depLoad.i.push(setter);\n // only run early setters when there are hoisted exports of that module\n // the timing works here as pending hoisted export calls will trigger through importerSetters\n if (depLoad.h || !depLoad.I)\n setter(depLoad.n);\n }\n return depLoad;\n });\n })\n }))\n .then(function (depLoads) {\n load.d = depLoads;\n });\n });\n\n linkPromise.catch(function (err) {\n load.e = null;\n load.er = err;\n });\n\n // Capital letter = a promise function\n return load = loader[REGISTRY][id] = {\n id: id,\n // importerSetters, the setters functions registered to this dependency\n // we retain this to add more later\n i: importerSetters,\n // module namespace object\n n: ns,\n\n // instantiate\n I: instantiatePromise,\n // link\n L: linkPromise,\n // whether it has hoisted exports\n h: false,\n\n // On instantiate completion we have populated:\n // dependency load records\n d: undefined,\n // execution function\n // set to NULL immediately after execution (or on any failure) to indicate execution has happened\n // in such a case, C should be used, and E, I, L will be emptied\n e: undefined,\n\n // On execution we have populated:\n // the execution error if any\n er: undefined,\n // in the case of TLA, the execution promise\n E: undefined,\n\n // On execution, L, I, E cleared\n\n // Promise for top-level completion\n C: undefined\n };\n }\n\n function instantiateAll (loader, load, loaded) {\n if (!loaded[load.id]) {\n loaded[load.id] = true;\n // load.L may be undefined for already-instantiated\n return Promise.resolve(load.L)\n .then(function () {\n return Promise.all(load.d.map(function (dep) {\n return instantiateAll(loader, dep, loaded);\n }));\n })\n }\n }\n\n function topLevelLoad (loader, load) {\n return load.C = instantiateAll(loader, load, {})\n .then(function () {\n return postOrderExec(loader, load, {});\n })\n .then(function () {\n return load.n;\n });\n }\n\n // the closest we can get to call(undefined)\n const nullContext = Object.freeze(Object.create(null));\n\n // returns a promise if and only if a top-level await subgraph\n // throws on sync errors\n function postOrderExec (loader, load, seen) {\n if (seen[load.id])\n return;\n seen[load.id] = true;\n\n if (!load.e) {\n if (load.er)\n throw load.er;\n if (load.E)\n return load.E;\n return;\n }\n\n // deps execute first, unless circular\n let depLoadPromises;\n load.d.forEach(function (depLoad) {\n {\n try {\n const depLoadPromise = postOrderExec(loader, depLoad, seen);\n if (depLoadPromise) {\n depLoadPromise.catch(function (err) {\n triggerOnload(loader, load, err);\n });\n (depLoadPromises = depLoadPromises || []).push(depLoadPromise);\n }\n }\n catch (err) {\n triggerOnload(loader, load, err);\n }\n }\n });\n if (depLoadPromises)\n return Promise.all(depLoadPromises).then(doExec);\n\n return doExec();\n\n function doExec () {\n try {\n let execPromise = load.e.call(nullContext);\n if (execPromise) {\n execPromise = execPromise.then(function () {\n load.C = load.n;\n load.E = null; // indicates completion\n triggerOnload(loader, load, null);\n }, function (err) {\n triggerOnload(loader, load, err);\n });\n return load.E = load.E || execPromise;\n }\n // (should be a promise, but a minify optimization to leave out Promise.resolve)\n load.C = load.n;\n triggerOnload(loader, load, null);\n }\n catch (err) {\n triggerOnload(loader, load, err);\n load.er = err;\n throw err;\n }\n finally {\n load.L = load.I = undefined;\n load.e = null;\n }\n }\n }\n\n envGlobal.System = new SystemJS();\n\n /*\n * Import map support for SystemJS\n * \n * \n * OR\n * \n * \n * Only those import maps available at the time of SystemJS initialization will be loaded\n * and they will be loaded in DOM order.\n * \n * There is no support for dynamic import maps injection currently.\n */\n\n let importMap = { imports: {}, scopes: {} }, importMapPromise;\n\n if (hasDocument) {\n Array.prototype.forEach.call(document.querySelectorAll('script[type=\"systemjs-importmap\"][src]'), function (script) {\n script._j = fetch(script.src).then(function (res) {\n return res.json();\n });\n });\n }\n\n systemJSPrototype.prepareImport = function () {\n if (!importMapPromise) {\n importMapPromise = Promise.resolve();\n if (hasDocument)\n Array.prototype.forEach.call(document.querySelectorAll('script[type=\"systemjs-importmap\"]'), function (script) {\n importMapPromise = importMapPromise.then(function () {\n return (script._j || script.src && fetch(script.src).then(function (resp) { return resp.json(); }) || Promise.resolve(JSON.parse(script.innerHTML)))\n .then(function (json) {\n importMap = resolveAndComposeImportMap(json, script.src || baseUrl, importMap);\n });\n });\n });\n }\n return importMapPromise;\n };\n\n systemJSPrototype.resolve = function (id, parentUrl) {\n parentUrl = parentUrl || baseUrl;\n return resolveImportMap(importMap, resolveIfNotPlainOrUrl(id, parentUrl) || id, parentUrl) || throwUnresolved(id, parentUrl);\n };\n\n function throwUnresolved (id, parentUrl) {\n throw Error(\"Unable to resolve specifier '\" + id + (parentUrl ? \"' from \" + parentUrl : \"'\"));\n }\n\n /*\n * Supports loading System.register via script tag injection\n */\n\n const systemRegister = systemJSPrototype.register;\n systemJSPrototype.register = function (deps, declare) {\n systemRegister.call(this, deps, declare);\n };\n\n systemJSPrototype.createScript = function (url) {\n const script = document.createElement('script');\n script.charset = 'utf-8';\n script.async = true;\n script.crossOrigin = 'anonymous';\n script.src = url;\n return script;\n };\n\n let lastWindowErrorUrl, lastWindowError;\n if (hasDocument)\n window.addEventListener('error', function (evt) {\n lastWindowErrorUrl = evt.filename;\n lastWindowError = evt.error;\n });\n\n systemJSPrototype.instantiate = function (url, firstParentUrl) {\n const loader = this;\n return new Promise(function (resolve, reject) {\n const script = systemJSPrototype.createScript(url);\n script.addEventListener('error', function () {\n reject(Error('Error loading ' + url + (firstParentUrl ? ' from ' + firstParentUrl : '')));\n });\n script.addEventListener('load', function () {\n document.head.removeChild(script);\n // Note that if an error occurs that isn't caught by this if statement,\n // that getRegister will return null and a \"did not instantiate\" error will be thrown.\n if (lastWindowErrorUrl === url) {\n reject(lastWindowError);\n }\n else {\n resolve(loader.getRegister());\n }\n });\n document.head.appendChild(script);\n });\n };\n\n if (hasDocument) {\n window.addEventListener('DOMContentLoaded', loadScriptModules);\n loadScriptModules();\n }\n\n function loadScriptModules() {\n Array.prototype.forEach.call(\n document.querySelectorAll('script[type=systemjs-module]'), function (script) {\n if (script.src) {\n System.import(script.src.slice(0, 7) === 'import:' ? script.src.slice(7) : resolveUrl(script.src, baseUrl));\n }\n });\n }\n\n /*\n * Supports loading System.register in workers\n */\n\n if (hasSelf && typeof importScripts === 'function')\n systemJSPrototype.instantiate = function (url) {\n const loader = this;\n return new Promise(function (resolve, reject) {\n try {\n importScripts(url);\n }\n catch (e) {\n reject(e);\n }\n resolve(loader.getRegister());\n });\n };\n\n /*\n * SystemJS global script loading support\n * Extra for the s.js build only\n * (Included by default in system.js build)\n */\n (function (global) {\n const systemJSPrototype = global.System.constructor.prototype;\n const isIE = navigator.userAgent.indexOf('Trident') !== -1;\n\n // safari unpredictably lists some new globals first or second in object order\n let firstGlobalProp, secondGlobalProp, lastGlobalProp;\n function getGlobalProp () {\n let cnt = 0;\n let lastProp;\n for (let p in global) {\n // do not check frames cause it could be removed during import\n if (\n !global.hasOwnProperty(p)\n || (!isNaN(p) && p < global.length)\n || (isIE && global[p] && global[p].parent === window)\n )\n continue;\n if (cnt === 0 && p !== firstGlobalProp || cnt === 1 && p !== secondGlobalProp)\n return p;\n cnt++;\n lastProp = p;\n }\n if (lastProp !== lastGlobalProp)\n return lastProp;\n }\n\n function noteGlobalProps () {\n // alternatively Object.keys(global).pop()\n // but this may be faster (pending benchmarks)\n firstGlobalProp = secondGlobalProp = undefined;\n for (let p in global) {\n // do not check frames cause it could be removed during import\n if (\n !global.hasOwnProperty(p)\n || (!isNaN(p) && p < global.length)\n || (isIE && global[p] && global[p].parent === window)\n )\n continue;\n if (!firstGlobalProp)\n firstGlobalProp = p;\n else if (!secondGlobalProp)\n secondGlobalProp = p;\n lastGlobalProp = p;\n }\n return lastGlobalProp;\n }\n\n const impt = systemJSPrototype.import;\n systemJSPrototype.import = function (id, parentUrl) {\n noteGlobalProps();\n return impt.call(this, id, parentUrl);\n };\n\n const emptyInstantiation = [[], function () { return {} }];\n\n const getRegister = systemJSPrototype.getRegister;\n systemJSPrototype.getRegister = function () {\n const lastRegister = getRegister.call(this);\n if (lastRegister)\n return lastRegister;\n\n // no registration -> attempt a global detection as difference from snapshot\n // when multiple globals, we take the global value to be the last defined new global object property\n // for performance, this will not support multi-version / global collisions as previous SystemJS versions did\n // note in Edge, deleting and re-adding a global does not change its ordering\n const globalProp = getGlobalProp();\n if (!globalProp)\n return emptyInstantiation;\n\n let globalExport;\n try {\n globalExport = global[globalProp];\n }\n catch (e) {\n return emptyInstantiation;\n }\n\n return [[], function (_export) {\n return {\n execute: function () {\n _export({ default: globalExport, __useDefault: true });\n }\n };\n }];\n };\n })(typeof self !== 'undefined' ? self : global);\n\n /*\n * Loads JSON, CSS, Wasm module types based on file extensions\n * Supports application/javascript falling back to JS eval\n */\n (function(global) {\n const systemJSPrototype = global.System.constructor.prototype;\n const instantiate = systemJSPrototype.instantiate;\n\n const moduleTypesRegEx = /\\.(css|html|json|wasm)$/;\n systemJSPrototype.shouldFetch = function (url) {\n const path = url.split('?')[0].split('#')[0];\n const ext = path.slice(path.lastIndexOf('.'));\n return ext.match(moduleTypesRegEx);\n };\n systemJSPrototype.fetch = function (url) {\n return fetch(url);\n };\n\n systemJSPrototype.instantiate = function (url, parent) {\n const loader = this;\n if (this.shouldFetch(url)) {\n return this.fetch(url)\n .then(function (res) {\n if (!res.ok)\n throw Error(res.status + ' ' + res.statusText + ', loading ' + url + (parent ? ' from ' + parent : ''));\n const contentType = res.headers.get('content-type');\n if (contentType.match(/^(text|application)\\/(x-)?javascript(;|$)/)) {\n return res.text().then(function (source) {\n (0, eval)(source);\n return loader.getRegister();\n });\n }\n else if (contentType.match(/^application\\/json(;|$)/)) {\n return res.text().then(function (source) {\n return [[], function (_export) {\n return {\n execute: function () {\n _export('default', JSON.parse(source));\n }\n };\n }];\n });\n }\n else if (contentType.match(/^text\\/css(;|$)/)) {\n return res.text().then(function (source) {\n return [[], function (_export) {\n return {\n execute: function () {\n // Relies on a Constructable Stylesheet polyfill\n const stylesheet = new CSSStyleSheet();\n stylesheet.replaceSync(source);\n _export('default', stylesheet);\n }\n };\n }];\n }); \n }\n else if (contentType.match(/^application\\/wasm(;|$)/)) {\n return (WebAssembly.compileStreaming ? WebAssembly.compileStreaming(res) : res.arrayBuffer().then(WebAssembly.compile))\n .then(function (module) {\n const deps = [];\n const setters = [];\n const importObj = {};\n \n // we can only set imports if supported (eg early Safari doesnt support)\n if (WebAssembly.Module.imports)\n WebAssembly.Module.imports(module).forEach(function (impt) {\n const key = impt.module;\n if (deps.indexOf(key) === -1) {\n deps.push(key);\n setters.push(function (m) {\n importObj[key] = m;\n });\n }\n });\n \n return [deps, function (_export) {\n return {\n setters: setters,\n execute: function () {\n return WebAssembly.instantiate(module, importObj)\n .then(function (instance) {\n _export(instance.exports);\n });\n }\n };\n }];\n });\n }\n else {\n throw new Error('Unknown module type \"' + contentType + '\"');\n }\n });\n }\n return instantiate.apply(this, arguments);\n };\n })(typeof self !== 'undefined' ? self : global);\n\n const toStringTag$1 = typeof Symbol !== 'undefined' && Symbol.toStringTag;\n\n systemJSPrototype.get = function (id) {\n const load = this[REGISTRY][id];\n if (load && load.e === null && !load.E) {\n if (load.er)\n return null;\n return load.n;\n }\n };\n\n systemJSPrototype.set = function (id, module) {\n let ns;\n if (toStringTag$1 && module[toStringTag$1] === 'Module') {\n ns = module;\n }\n else {\n ns = Object.assign(Object.create(null), module);\n if (toStringTag$1)\n Object.defineProperty(ns, toStringTag$1, { value: 'Module' });\n }\n\n const done = Promise.resolve(ns);\n\n const load = this[REGISTRY][id] || (this[REGISTRY][id] = {\n id: id,\n i: [],\n h: false,\n d: [],\n e: null,\n er: undefined,\n E: undefined\n });\n\n if (load.e || load.E)\n return false;\n \n Object.assign(load, {\n n: ns,\n I: undefined,\n L: undefined,\n C: done\n });\n return ns;\n };\n\n systemJSPrototype.has = function (id) {\n const load = this[REGISTRY][id];\n return !!load;\n };\n\n // Delete function provided for hot-reloading use cases\n systemJSPrototype.delete = function (id) {\n const registry = this[REGISTRY];\n const load = registry[id];\n // in future we can support load.E case by failing load first\n // but that will require TLA callbacks to be implemented\n if (!load || load.e !== null || load.E)\n return false;\n\n let importerSetters = load.i;\n // remove from importerSetters\n // (release for gc)\n if (load.d)\n load.d.forEach(function (depLoad) {\n const importerIndex = depLoad.i.indexOf(load);\n if (importerIndex !== -1)\n depLoad.i.splice(importerIndex, 1);\n });\n delete registry[id];\n return function () {\n const load = registry[id];\n if (!load || !importerSetters || load.e !== null || load.E)\n return false;\n // add back the old setters\n importerSetters.forEach(function (setter) {\n load.i.push(setter);\n setter(load.n);\n });\n importerSetters = null;\n };\n };\n\n const iterator = typeof Symbol !== 'undefined' && Symbol.iterator;\n\n systemJSPrototype.entries = function () {\n const loader = this, keys = Object.keys(loader[REGISTRY]);\n let index = 0, ns, key;\n const result = {\n next: function () {\n while (\n (key = keys[index++]) !== undefined && \n (ns = loader.get(key)) === undefined\n );\n return {\n done: key === undefined,\n value: key !== undefined && [key, ns]\n };\n }\n };\n\n result[iterator] = function() { return this };\n\n return result;\n };\n\n}());\n","var g;\n\n// This works in non-strict mode\ng = (function() {\n\treturn this;\n})();\n\ntry {\n\t// This works if eval is allowed (see CSP)\n\tg = g || new Function(\"return this\")();\n} catch (e) {\n\t// This works if the window reference is available\n\tif (typeof window === \"object\") g = window;\n}\n\n// g can still be undefined, but nothing to do about it...\n// We return undefined, instead of nothing here, so it's\n// easier to handle this case. if(!global) { ...}\n\nmodule.exports = g;\n","module.exports = function(module) {\n\tif (!module.webpackPolyfill) {\n\t\tmodule.deprecate = function() {};\n\t\tmodule.paths = [];\n\t\t// module.parent = undefined by default\n\t\tif (!module.children) module.children = [];\n\t\tObject.defineProperty(module, \"loaded\", {\n\t\t\tenumerable: true,\n\t\t\tget: function() {\n\t\t\t\treturn module.l;\n\t\t\t}\n\t\t});\n\t\tObject.defineProperty(module, \"id\", {\n\t\t\tenumerable: true,\n\t\t\tget: function() {\n\t\t\t\treturn module.i;\n\t\t\t}\n\t\t});\n\t\tmodule.webpackPolyfill = 1;\n\t}\n\treturn module;\n};\n","const sysytemJs = require('systemjs/dist/system')\n\nmodule.export = ({ apps, navigations, config }) => {\n sysytemJs.import('./main/index.js')\n};"],"sourceRoot":""} \ No newline at end of file diff --git a/src/main.js b/src/main.js new file mode 100644 index 0000000..c072d62 --- /dev/null +++ b/src/main.js @@ -0,0 +1,7 @@ +const sysytemJs = require("systemjs/dist/system"); + +module.export = ({ apps, navigations, config }) => { + console.log("apps", apps); + + sysytemJs.import("./main/index.js"); +}; diff --git a/webpack.config.js b/webpack.config.js index 93dd6ff..a1e88c1 100644 --- a/webpack.config.js +++ b/webpack.config.js @@ -8,14 +8,11 @@ const outputDirectory = 'dist'; module.exports = { mode: 'development', entry: { - bootstrap: ['./src/main.tsx'], - example: ['./src/example/main.tsx'], - example2: ['./src/example2/main.tsx'] + bootstrap: ['./src/main.js'] }, output: { filename: '[name].js', path: path.resolve(__dirname, outputDirectory), - libraryTarget: 'umd', globalObject: `(typeof self !== 'undefined' ? self : this)` }, node: { @@ -25,17 +22,7 @@ module.exports = { new CleanWebpackPlugin(), new webpack.DefinePlugin({ 'typeof window': JSON.stringify('object') - }), - new webpackCopy([ - { from: 'stubs/index.html' }, - { from: 'stubs/importmap.json' }, - { from: './node_modules/systemjs/dist', to: 'extlib/systemjs' }, - { from: './node_modules/react/umd', to: 'extlib/react' }, - { from: './node_modules/react-dom/umd', to: 'extlib/react-dom' }, - { from: './node_modules/uds-news-original/dist' }, - { from: './node_modules/uds-org/dist' }, - { from: './node_modules/uds-sections-origin/dist' } - ]) + }) ], devtool: '#source-map', //devtool: 'none', @@ -57,12 +44,5 @@ module.exports = { } ] - }, - externals: { - 'react': 'react', - 'react-dom': 'react-dom', - 'redux': 'redux', - 'react-redux': 'react-redux', - 'styled-components': 'styled-components' } };