Skip to content
This repository was archived by the owner on Jul 13, 2020. It is now read-only.

Commit 69b38ce

Browse files
committed
0.7.2
1 parent cce5611 commit 69b38ce

8 files changed

+33
-31
lines changed

README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,14 +2,14 @@
22

33
Dynamically loads ES6 modules in NodeJS and current browsers.
44

5-
* Implemented exactly to the May 22 2014 ES6 specification draft.
5+
* Implemented exactly to the July 18 2014 ES6 specification draft.
66
* Provides an asynchronous loader (`System.import`) to [dynamically load ES6 modules](#basic-use).
77
* Uses [Traceur](https://github.com/google/traceur-compiler) for compiling ES6 modules and syntax into ES5 in the browser with source map support.
88
* Fully supports [ES6 circular references and bindings](#circular-references--bindings).
9-
* Polyfills ES6 Promises in the browser with a bundled [es6-promise](https://github.com/jakearchibald/es6-promise) implementation.
9+
* Polyfills ES6 Promises in the browser with an optionally bundled ES6 promise implementation.
1010
* [Compatible with NodeJS](#nodejs-usage) allowing for server-side module loading and tracing extensions.
11-
* Supports ES6 module loading in IE9+, and dynamic module formats in IE8+.
12-
* The complete combined polyfill comes to 8.7KB minified and gzipped, making it suitable for production use, provided that modules are [built into ES5 making them independent of Traceur](#moving-to-production).
11+
* Supports ES6 module loading in IE8+. Other ES6 features only supported by Traceur in IE9+.
12+
* The complete combined polyfill comes to 8.4KB minified and gzipped, making it suitable for production use, provided that modules are [built into ES5 making them independent of Traceur](#moving-to-production).
1313

1414
For an overview of build workflows, [see the production guide](#moving-to-production).
1515

bower.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
{
22
"name": "es6-module-loader",
3-
"version": "0.7.1",
3+
"version": "0.7.2",
44
"description": "An ES6 Module Loader polyfill based on the latest spec.",
55
"homepage": "https://github.com/ModuleLoader/es6-module-loader",
66
"main": "dist/es6-module-loader-sans-promises.js",
77
"dependencies": {
8-
"traceur": "0.0.49"
8+
"traceur": "0.0.52"
99
},
1010
"keywords": [
1111
"es6",

dist/es6-module-loader-sans-promises.js

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
44
Loader Polyfill
55
6-
- Implemented exactly to the 2014-05-22 Specification Draft.
6+
- Implemented exactly to the 2014-07-18 Specification Draft.
77
88
- Functions are commented with their spec numbers, with spec differences commented.
99
@@ -170,7 +170,8 @@ function logloads(loads) {
170170
step: options.address ? 'fetch' : 'locate',
171171
loader: loader,
172172
moduleName: name,
173-
moduleMetadata: {},
173+
// allow metadata for import https://bugs.ecmascript.org/show_bug.cgi?id=3091
174+
moduleMetadata: options && options.metadata || {},
174175
moduleSource: options.source,
175176
moduleAddress: options.address
176177
}));
@@ -694,7 +695,7 @@ function logloads(loads) {
694695
for (var i = 0, l = module.importers.length; i < l; i++) {
695696
var importerModule = module.importers[i];
696697
if (!importerModule.locked) {
697-
var importerIndex = importerModule.dependencies.indexOf(module);
698+
var importerIndex = indexOf.call(importerModule.dependencies, module);
698699
importerModule.setters[importerIndex](moduleObj);
699700
}
700701
}
@@ -816,14 +817,14 @@ function logloads(loads) {
816817

817818
module.evaluated = true;
818819
err = doExecute(module);
819-
if (err)
820+
if (err) {
820821
module.failed = true;
821-
822-
// spec variation
823-
// we don't create a new module here because it was created and ammended
824-
// we just disable further extensions instead
825-
if (Object.preventExtensions)
822+
} else if (Object.preventExtensions) {
823+
// spec variation
824+
// we don't create a new module here because it was created and ammended
825+
// we just disable further extensions instead
826826
Object.preventExtensions(module.module);
827+
}
827828

828829
module.execute = undefined;
829830
return err;

dist/es6-module-loader-sans-promises.min.js

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/es6-module-loader.js

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1177,7 +1177,7 @@ define(function(require) {
11771177
11781178
Loader Polyfill
11791179
1180-
- Implemented exactly to the 2014-05-22 Specification Draft.
1180+
- Implemented exactly to the 2014-07-18 Specification Draft.
11811181
11821182
- Functions are commented with their spec numbers, with spec differences commented.
11831183
@@ -1344,7 +1344,8 @@ function logloads(loads) {
13441344
step: options.address ? 'fetch' : 'locate',
13451345
loader: loader,
13461346
moduleName: name,
1347-
moduleMetadata: {},
1347+
// allow metadata for import https://bugs.ecmascript.org/show_bug.cgi?id=3091
1348+
moduleMetadata: options && options.metadata || {},
13481349
moduleSource: options.source,
13491350
moduleAddress: options.address
13501351
}));
@@ -1868,7 +1869,7 @@ function logloads(loads) {
18681869
for (var i = 0, l = module.importers.length; i < l; i++) {
18691870
var importerModule = module.importers[i];
18701871
if (!importerModule.locked) {
1871-
var importerIndex = importerModule.dependencies.indexOf(module);
1872+
var importerIndex = indexOf.call(importerModule.dependencies, module);
18721873
importerModule.setters[importerIndex](moduleObj);
18731874
}
18741875
}
@@ -1990,14 +1991,14 @@ function logloads(loads) {
19901991

19911992
module.evaluated = true;
19921993
err = doExecute(module);
1993-
if (err)
1994+
if (err) {
19941995
module.failed = true;
1995-
1996-
// spec variation
1997-
// we don't create a new module here because it was created and ammended
1998-
// we just disable further extensions instead
1999-
if (Object.preventExtensions)
1996+
} else if (Object.preventExtensions) {
1997+
// spec variation
1998+
// we don't create a new module here because it was created and ammended
1999+
// we just disable further extensions instead
20002000
Object.preventExtensions(module.module);
2001+
}
20012002

20022003
module.execute = undefined;
20032004
return err;

dist/es6-module-loader.min.js

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

lib/loader.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
44
Loader Polyfill
55
6-
- Implemented exactly to the 2014-05-22 Specification Draft.
6+
- Implemented exactly to the 2014-07-18 Specification Draft.
77
88
- Functions are commented with their spec numbers, with spec differences commented.
99
@@ -695,7 +695,7 @@ function logloads(loads) {
695695
for (var i = 0, l = module.importers.length; i < l; i++) {
696696
var importerModule = module.importers[i];
697697
if (!importerModule.locked) {
698-
var importerIndex = importerModule.dependencies.indexOf(module);
698+
var importerIndex = indexOf.call(importerModule.dependencies, module);
699699
importerModule.setters[importerIndex](moduleObj);
700700
}
701701
}

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "es6-module-loader",
33
"description": "An ES6 Module Loader shim",
4-
"version": "0.7.1",
4+
"version": "0.7.2",
55
"homepage": "https://github.com/ModuleLoader/es6-module-loader",
66
"author": {
77
"name": "Guy Bedford, Luke Hoban, Addy Osmani",

0 commit comments

Comments
 (0)