You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Jul 13, 2020. It is now read-only.
Copy file name to clipboardExpand all lines: README.md
+9-3Lines changed: 9 additions & 3 deletions
Original file line number
Diff line number
Diff line change
@@ -49,16 +49,22 @@ We can then load the module with the dynamic loader:
49
49
<script>
50
50
System.import('mymodule').then(function(m) {
51
51
newm.q();
52
-
}).catch(console.error.bind(console));
52
+
});
53
53
</script>
54
54
```
55
55
56
56
The dynamic loader returns a `Module` object, which contains getters for the named exports (in this case, `q`).
57
57
58
-
_Because the loader is promise-based we need to add a catch handler in order to detect loading errors._
59
-
60
58
[Read the wiki on overview of ES6 modules and syntax](https://github.com/ModuleLoader/es6-module-loader/wiki/A-Brief-ES6-Modules-Overview).
61
59
60
+
### Custom Compilation Options
61
+
62
+
Custom [Traceur compilation options](https://github.com/google/traceur-compiler/blob/master/src/Options.js#L25) can be set through `System.traceurOptions`, eg:
63
+
64
+
```javascript
65
+
System.traceurOptions.annotations=true;
66
+
```
67
+
62
68
### Module Tag
63
69
64
70
A simple analog to the module tag is provided with:
0 commit comments