mirror of
https://github.com/bakhirev/assayo.git
synced 2024-11-16 08:11:40 +00:00
19 lines
478 B
JavaScript
19 lines
478 B
JavaScript
|
module.exports = {
|
||
|
webpack: (config) => {
|
||
|
|
||
|
|
||
|
const oneOfs = config.module.rules.find((rule) => !!rule.oneOf).oneOf;
|
||
|
for (const oneOf of oneOfs) {
|
||
|
oneOf?.use?.forEach((someUse) => {
|
||
|
if (!someUse?.options?.modules?.mode) return;
|
||
|
// someUse.options.modules.localIdentName = '[local]_';
|
||
|
someUse.options.modules.getLocalIdent = (context, localIdentName, localName, options) => {
|
||
|
return localName;
|
||
|
}
|
||
|
});
|
||
|
}
|
||
|
|
||
|
return config;
|
||
|
}
|
||
|
};
|