mirror of
https://github.com/systemjs/systemjs.git
synced 2026-01-18 14:53:14 +00:00
share baseURI from module loader wrapper
This commit is contained in:
parent
d0eef8fd07
commit
24e9d4e4b2
@ -2,7 +2,6 @@ var absURLRegEx = /^[^\/]+:\/\//;
|
||||
|
||||
// caches baseURL URL object
|
||||
// also allows baseURL to be relative to the baseURI
|
||||
var baseURI;
|
||||
function getAbsBaseURL() {
|
||||
var baseURL = this.baseURL;
|
||||
return baseURLCache[baseURL] = baseURLCache[baseURL] || new URL(baseURL + (baseURL[baseURL.length - 1] != '/' ? '/' : ''), baseURI);
|
||||
@ -14,9 +13,6 @@ hookConstructor(function(constructor) {
|
||||
return function() {
|
||||
constructor.call(this);
|
||||
|
||||
// by default ModuleLoader sets this.baseURL to baseURI
|
||||
baseURI = this.baseURL;
|
||||
|
||||
// support the empty module, as a concept
|
||||
this.set('@empty', this.newModule({}));
|
||||
};
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user