describe: modify absolute path to relative path in source map file.

Feature or Bugfix: Bugfix
Binary Source:Yes
Signed-off-by: youbing54<youbing3@huawei.com>
This commit is contained in:
youbing54 2024-08-14 21:02:23 +08:00
parent 37eb237e85
commit c35cfa5f31

View File

@ -47,9 +47,7 @@ const webpackConfig = {
},
output: {
filename: '[name].js',
devtoolModuleFilenameTemplate: (info) => {
return `${info.absoluteResourcePath.replace(process.env.projectRootPath + path.sep, '')}`;
},
devtoolModuleFilenameTemplate: 'webpack:///[absolute-resource-path]'
},
devtool: 'nosources-source-map',
mode: 'development',