Skip to content

Commit 6e61f71

Browse files
authored
clean experiments.importAwait and experiments.importAsync (#3892)
1 parent e29a299 commit 6e61f71

File tree

3 files changed

+3
-7
lines changed

3 files changed

+3
-7
lines changed

src/content/configuration/experiments.md

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,6 @@ Available options:
2121
- `syncWebAssembly`: Support the old WebAssembly like in webpack 4
2222
- `asyncWebAssembly`: Support the new WebAssembly according to the [updated specification](https://github.com/WebAssembly/esm-integration), it makes a WebAssembly module an async module
2323
- `topLevelAwait`: Support the [Top Level Await Stage 3 proposal](https://github.com/tc39/proposal-top-level-await), it makes the module an async module when `await` is used on the top-level
24-
- `importAsync`: import async modules with `import`
25-
- `importAwait`: import async modules with `import await`
2624
- `asset`: a type of module that allows to use asset files (fonts, images, etc) without configuring loaders to handle their importing, similar to `file-loader` | `url-loader` | `raw-loader`
2725
- `outputModule`: enables the use of [`output.module`](/configuration/output/#outputmodule) configuration option and sets it to `true`. Enables the use of `output.libraryTarget` as `'module'` and sets it to `'module'`.
2826

@@ -38,8 +36,6 @@ module.exports = {
3836
topLevelAwait: true,
3937
asset: true,
4038
asyncWebAssembly: true,
41-
importAsync: true,
42-
importAwait: true,
4339
},
4440
};
4541
```

src/content/configuration/externals.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -319,8 +319,8 @@ Supported types:
319319
- `'umd2'`
320320
- `'jsonp'`
321321
- `'system'`
322-
- `'promise'` - same as `'var'` but awaits the result (async module, depends on [`experiments.importAsync`](/configuration/experiments/))
323-
- `'import'` - uses `import()` to load a native EcmaScript module (async module, depends on [`experiments.importAsync`](/configuration/experiments/))
322+
- `'promise'` - same as `'var'` but awaits the result (async module)
323+
- `'import'` - uses `import()` to load a native EcmaScript module (async module)
324324

325325
__webpack.config.js__
326326

src/content/migrate/5.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,7 @@ Yarn: `yarn add webpack@next -D`
106106
If you were using WASM via import you should follow this two step process:
107107

108108
- Enable the deprecated spec by setting `experiments.syncWebAssembly: true`, to get the same behavior as in webpack 4.
109-
- After successful migration to webpack 5, change the `experiments` value to `experiments: { asyncWebAssembly: true, importAsync: true }` to use the up-to-date spec for WASM integration.
109+
- After successful migration to webpack 5, change the `experiments` value to `experiments: { asyncWebAssembly: true }` to use the up-to-date spec for WASM integration.
110110

111111
Reconsider `optimization.splitChunks`:
112112

0 commit comments

Comments
 (0)