minor fixes
This commit is contained in:
parent
faf784b6ab
commit
4b499b0429
|
@ -640,11 +640,9 @@ function webpackAsyncContextResolve(req) {
|
|||
return map[req];
|
||||
});
|
||||
}
|
||||
webpackAsyncContext.keys = ${
|
||||
arrow ? "_ => {" : "function webpackAsyncContextKeys() {"
|
||||
}
|
||||
return Object.keys(map);
|
||||
};
|
||||
webpackAsyncContext.keys = ${runtimeTemplate.returningFunction(
|
||||
"Object.keys(map)"
|
||||
)};
|
||||
webpackAsyncContext.resolve = webpackAsyncContextResolve;
|
||||
webpackAsyncContext.id = ${JSON.stringify(id)};
|
||||
module.exports = webpackAsyncContext;`;
|
||||
|
@ -686,11 +684,9 @@ function webpackAsyncContextResolve(req) {
|
|||
return map[req];
|
||||
});
|
||||
}
|
||||
webpackAsyncContext.keys = ${
|
||||
arrow ? "_ => {" : "function webpackAsyncContextKeys() {"
|
||||
}
|
||||
return Object.keys(map);
|
||||
};
|
||||
webpackAsyncContext.keys = ${runtimeTemplate.returningFunction(
|
||||
"Object.keys(map)"
|
||||
)};
|
||||
webpackAsyncContext.resolve = webpackAsyncContextResolve;
|
||||
webpackAsyncContext.id = ${JSON.stringify(id)};
|
||||
module.exports = webpackAsyncContext;`;
|
||||
|
@ -738,11 +734,9 @@ function webpackAsyncContextResolve(req) {
|
|||
return map[req];
|
||||
});
|
||||
}
|
||||
webpackAsyncContext.keys = ${
|
||||
arrow ? "_ => {" : "function webpackAsyncContextKeys() {"
|
||||
}
|
||||
return Object.keys(map);
|
||||
};
|
||||
webpackAsyncContext.keys = ${runtimeTemplate.returningFunction(
|
||||
"Object.keys(map)"
|
||||
)};
|
||||
webpackAsyncContext.resolve = webpackAsyncContextResolve;
|
||||
webpackAsyncContext.id = ${JSON.stringify(id)};
|
||||
module.exports = webpackAsyncContext;`;
|
||||
|
@ -854,11 +848,9 @@ function webpackAsyncContext(req) {
|
|||
|
||||
return `var map = ${JSON.stringify(map, null, "\t")};
|
||||
${webpackAsyncContext}
|
||||
webpackAsyncContext.keys = ${
|
||||
arrow ? "_ => {" : "function webpackAsyncContextKeys() {"
|
||||
}
|
||||
return Object.keys(map);
|
||||
};
|
||||
webpackAsyncContext.keys = ${runtimeTemplate.returningFunction(
|
||||
"Object.keys(map)"
|
||||
)};
|
||||
webpackAsyncContext.id = ${JSON.stringify(id)};
|
||||
module.exports = webpackAsyncContext;`;
|
||||
}
|
||||
|
|
|
@ -448,30 +448,30 @@ class RuntimeTemplate {
|
|||
} else if (strict) {
|
||||
runtimeRequirements.add(RuntimeGlobals.createFakeNamespaceObject);
|
||||
if (header) {
|
||||
getModuleFunction = this.basicFunction(
|
||||
"",
|
||||
`${header}return ${RuntimeGlobals.createFakeNamespaceObject}(${moduleIdExpr}, 1)`
|
||||
);
|
||||
const returnExpression = `${RuntimeGlobals.createFakeNamespaceObject}(${moduleIdExpr}, 1)`;
|
||||
getModuleFunction = header
|
||||
? this.basicFunction("", `${header}return ${returnExpression}`)
|
||||
: this.returningFunction(returnExpression);
|
||||
} else {
|
||||
getModuleFunction = `${RuntimeGlobals.createFakeNamespaceObject}.bind(__webpack_require__, ${comment}${idExpr}, 1)`;
|
||||
}
|
||||
} else if (exportsType === "default") {
|
||||
runtimeRequirements.add(RuntimeGlobals.createFakeNamespaceObject);
|
||||
if (header) {
|
||||
getModuleFunction = this.basicFunction(
|
||||
"",
|
||||
`${header}return ${RuntimeGlobals.createFakeNamespaceObject}(${moduleIdExpr}, 3)`
|
||||
);
|
||||
const returnExpression = `${RuntimeGlobals.createFakeNamespaceObject}(${moduleIdExpr}, 3)`;
|
||||
getModuleFunction = header
|
||||
? this.basicFunction("", `${header}return ${returnExpression}`)
|
||||
: this.returningFunction(returnExpression);
|
||||
} else {
|
||||
getModuleFunction = `${RuntimeGlobals.createFakeNamespaceObject}.bind(__webpack_require__, ${comment}${idExpr}, 3)`;
|
||||
}
|
||||
} else {
|
||||
runtimeRequirements.add(RuntimeGlobals.createFakeNamespaceObject);
|
||||
if (header) {
|
||||
getModuleFunction = this.basicFunction(
|
||||
"",
|
||||
`${header}return ${RuntimeGlobals.createFakeNamespaceObject}(${moduleIdExpr}, 7)`
|
||||
);
|
||||
const returnExpression = `${RuntimeGlobals.createFakeNamespaceObject}(${moduleIdExpr}, 7)`;
|
||||
getModuleFunction = header
|
||||
? this.basicFunction("", `${header}return ${returnExpression}`)
|
||||
: this.returningFunction(returnExpression);
|
||||
} else {
|
||||
getModuleFunction = `${RuntimeGlobals.createFakeNamespaceObject}.bind(__webpack_require__, ${comment}${idExpr}, 7)`;
|
||||
}
|
||||
|
|
|
@ -1165,7 +1165,7 @@ Built at: 1970-04-20 12:42:42
|
|||
398.js 484 bytes [emitted]
|
||||
544.js 484 bytes [emitted]
|
||||
718.js 484 bytes [emitted]
|
||||
entry.js 9.63 KiB [emitted] [name: entry]
|
||||
entry.js 9.61 KiB [emitted] [name: entry]
|
||||
Entrypoint entry = entry.js
|
||||
./entry.js 450 bytes [built]
|
||||
./templates lazy ^\\\\.\\\\/.*$ include: \\\\.js$ exclude: \\\\.noimport\\\\.js$ namespace object 160 bytes [optional] [built]
|
||||
|
|
Loading…
Reference in New Issue