diff options
author | Bartek IwaĆczuk <biwanczuk@gmail.com> | 2020-06-17 19:44:40 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-06-17 19:44:40 +0200 |
commit | e60922981be918ba4e6d9d857d9834b0d586df5b (patch) | |
tree | 39f260d605a0a8cf4efec71d77e927e7970cd8e6 /deno_typescript/README.md | |
parent | 75bb9dbdfc7f8b4e8d17978808ae575e61843aef (diff) |
Revert "Deno.bundle supports targets < ES2017. (#6328)" (#6342)
This reverts commit 75bb9dbdfc7f8b4e8d17978808ae575e61843aef.
Diffstat (limited to 'deno_typescript/README.md')
-rw-r--r-- | deno_typescript/README.md | 17 |
1 files changed, 6 insertions, 11 deletions
diff --git a/deno_typescript/README.md b/deno_typescript/README.md index 7ee4cf1df..70fe74773 100644 --- a/deno_typescript/README.md +++ b/deno_typescript/README.md @@ -69,14 +69,9 @@ At the time of this writing, while V8 and other JavaScript engines have implemented top-level-await, no browsers have it implemented, meaning that most browsers could not consume modules that require top-level-await. -In order to allow more browsers to consume bundles, there is an argument that is -passed to the `__instantiate()` function which determines if the code is -bootstrapped asynchronously or not. When emitting a bundle that contains a -module that requires top-level-await, Deno will detect this and utilise -`await __instantiate(main, true)`. - -The `system_loader_es5.js` is a transpiled version of `system_loader.js` that is -designed to work with ES5 or later, and will be used when the bundle target is < -ES2017. While ES3 is still a potential target which can be passed in a -`tsconfig.json` to Deno, any resulting bundle will not be compatible, as there -is a need to utilise items like `Object.defineProperty()`. +In order to facilitate this, there are two functions that are in the scope of +the module in addition to the `System.register()` method. `__instantiate(main)` +will bootstrap everything synchronously and `__instantiateAsync(main)` will do +so asynchronously. When emitting a bundle that contains a module that requires +top-level-await, Deno will detect this and utilise +`await __instantiateAsync(main)` instead. |