rollup 0.45.1 → 0.45.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +6 -0
- package/LICENSE.md +1 -1
- package/bin/rollup +5 -1
- package/dist/rollup.browser.js +16 -11
- package/dist/rollup.browser.js.map +1 -1
- package/dist/rollup.es.js +16 -11
- package/dist/rollup.es.js.map +1 -1
- package/dist/rollup.js +16 -11
- package/dist/rollup.js.map +1 -1
- package/package.json +2 -1
package/dist/rollup.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/*
|
|
2
|
-
Rollup.js v0.45.
|
|
3
|
-
|
|
2
|
+
Rollup.js v0.45.2
|
|
3
|
+
Wed Jul 12 2017 22:24:48 GMT-0400 (EDT) - commit b7a4edf2b7c26f58c8201a63c820541d9b37186d
|
|
4
4
|
|
|
5
5
|
|
|
6
6
|
https://github.com/rollup/rollup
|
|
@@ -8146,6 +8146,7 @@ var Module = function Module (ref) {
|
|
|
8146
8146
|
var ast = ref.ast;
|
|
8147
8147
|
var sourceMapChain = ref.sourceMapChain;
|
|
8148
8148
|
var resolvedIds = ref.resolvedIds;
|
|
8149
|
+
var resolvedExternalIds = ref.resolvedExternalIds;
|
|
8149
8150
|
var bundle = ref.bundle;
|
|
8150
8151
|
|
|
8151
8152
|
this.code = code;
|
|
@@ -8178,6 +8179,7 @@ var Module = function Module (ref) {
|
|
|
8178
8179
|
this.sources = [];
|
|
8179
8180
|
this.dependencies = [];
|
|
8180
8181
|
this.resolvedIds = resolvedIds || blank();
|
|
8182
|
+
this.resolvedExternalIds = resolvedExternalIds || blank();
|
|
8181
8183
|
|
|
8182
8184
|
// imports and exports, indexed by local name
|
|
8183
8185
|
this.imports = blank();
|
|
@@ -8382,21 +8384,23 @@ Module.prototype.bindImportSpecifiers = function bindImportSpecifiers () {
|
|
|
8382
8384
|
keys( specifiers ).forEach( function (name) {
|
|
8383
8385
|
var specifier = specifiers[ name ];
|
|
8384
8386
|
|
|
8385
|
-
var id = this$1.resolvedIds[ specifier.source ];
|
|
8387
|
+
var id = this$1.resolvedIds[ specifier.source ] || this$1.resolvedExternalIds[ specifier.source ];
|
|
8386
8388
|
specifier.module = this$1.bundle.moduleById.get( id );
|
|
8387
8389
|
});
|
|
8388
8390
|
});
|
|
8389
8391
|
|
|
8390
8392
|
this.exportAllModules = this.exportAllSources.map( function (source) {
|
|
8391
|
-
var id = this$1.resolvedIds[ source ];
|
|
8393
|
+
var id = this$1.resolvedIds[ source ] || this$1.resolvedExternalIds[ source ];
|
|
8392
8394
|
return this$1.bundle.moduleById.get( id );
|
|
8393
8395
|
});
|
|
8394
8396
|
|
|
8395
8397
|
this.sources.forEach( function (source) {
|
|
8396
8398
|
var id = this$1.resolvedIds[ source ];
|
|
8397
|
-
var module = this$1.bundle.moduleById.get( id );
|
|
8398
8399
|
|
|
8399
|
-
if (
|
|
8400
|
+
if ( id ) {
|
|
8401
|
+
var module = this$1.bundle.moduleById.get( id );
|
|
8402
|
+
this$1.dependencies.push( module );
|
|
8403
|
+
}
|
|
8400
8404
|
});
|
|
8401
8405
|
};
|
|
8402
8406
|
|
|
@@ -8507,7 +8511,8 @@ Module.prototype.toJSON = function toJSON () {
|
|
|
8507
8511
|
originalSourceMap: this.originalSourceMap,
|
|
8508
8512
|
ast: this.astClone,
|
|
8509
8513
|
sourceMapChain: this.sourceMapChain,
|
|
8510
|
-
resolvedIds: this.resolvedIds
|
|
8514
|
+
resolvedIds: this.resolvedIds,
|
|
8515
|
+
resolvedExternalIds: this.resolvedExternalIds
|
|
8511
8516
|
};
|
|
8512
8517
|
};
|
|
8513
8518
|
|
|
@@ -8659,7 +8664,7 @@ function getInteropBlock ( bundle, options ) {
|
|
|
8659
8664
|
return ((bundle.varOrConst) + " " + (module.name) + "__default = 'default' in " + (module.name) + " ? " + (module.name) + "['default'] : " + (module.name) + ";");
|
|
8660
8665
|
}
|
|
8661
8666
|
|
|
8662
|
-
return ((module.name) + " = " + (module.name) + " &&
|
|
8667
|
+
return ((module.name) + " = " + (module.name) + " && " + (module.name) + ".hasOwnProperty('default') ? " + (module.name) + "['default'] : " + (module.name) + ";");
|
|
8663
8668
|
})
|
|
8664
8669
|
.filter( Boolean )
|
|
8665
8670
|
.join( '\n' );
|
|
@@ -10023,7 +10028,7 @@ Bundle.prototype.fetchModule = function fetchModule ( id, importer ) {
|
|
|
10023
10028
|
}
|
|
10024
10029
|
});
|
|
10025
10030
|
module.exportAllSources.forEach( function (source) {
|
|
10026
|
-
var id = module.resolvedIds[ source ];
|
|
10031
|
+
var id = module.resolvedIds[ source ] || module.resolvedExternalIds[ source ];
|
|
10027
10032
|
var exportAllModule = this$1.moduleById.get( id );
|
|
10028
10033
|
if ( exportAllModule.isExternal ) { return; }
|
|
10029
10034
|
|
|
@@ -10073,7 +10078,7 @@ Bundle.prototype.fetchAllDependencies = function fetchAllDependencies ( module )
|
|
|
10073
10078
|
}
|
|
10074
10079
|
|
|
10075
10080
|
if ( isExternal ) {
|
|
10076
|
-
module.
|
|
10081
|
+
module.resolvedExternalIds[ source ] = externalId;
|
|
10077
10082
|
|
|
10078
10083
|
if ( !this$1.moduleById.has( externalId ) ) {
|
|
10079
10084
|
var module$1 = new ExternalModule( externalId, this$1.getPath( externalId ) );
|
|
@@ -10345,7 +10350,7 @@ Bundle.prototype.warn = function warn ( warning ) {
|
|
|
10345
10350
|
this.onwarn( warning );
|
|
10346
10351
|
};
|
|
10347
10352
|
|
|
10348
|
-
var VERSION = '0.45.
|
|
10353
|
+
var VERSION = '0.45.2';
|
|
10349
10354
|
|
|
10350
10355
|
var ALLOWED_KEYS = [
|
|
10351
10356
|
'acorn',
|