main
Last change
on this file since 79a0317 was 79a0317, checked in by stefan toskovski <stefantoska84@…>, 4 days ago |
F4 Finalna Verzija
|
-
Property mode
set to
100644
|
File size:
637 bytes
|
Rev | Line | |
---|
[79a0317] | 1 | module.exports = function injectCaller(opts, target) {
|
---|
| 2 | return Object.assign({}, opts, {
|
---|
| 3 | caller: Object.assign({
|
---|
| 4 | name: "babel-loader",
|
---|
| 5 | // Provide plugins with insight into webpack target.
|
---|
| 6 | // https://github.com/babel/babel-loader/issues/787
|
---|
| 7 | target,
|
---|
| 8 | // Webpack >= 2 supports ESM and dynamic import.
|
---|
| 9 | supportsStaticESM: true,
|
---|
| 10 | supportsDynamicImport: true,
|
---|
| 11 | // Webpack 5 supports TLA behind a flag. We enable it by default
|
---|
| 12 | // for Babel, and then webpack will throw an error if the experimental
|
---|
| 13 | // flag isn't enabled.
|
---|
| 14 | supportsTopLevelAwait: true
|
---|
| 15 | }, opts.caller)
|
---|
| 16 | });
|
---|
| 17 | }; |
---|
Note:
See
TracBrowser
for help on using the repository browser.