mirror of
https://github.com/element-hq/element-web
synced 2024-11-28 20:38:55 +03:00
Slightly improve source path tree in the browser debugger
This commit is contained in:
parent
48924a6106
commit
4b904d90f2
1 changed files with 12 additions and 0 deletions
|
@ -11,6 +11,18 @@ module.exports = {
|
||||||
{ test: /\.js$/, loader: "babel", include: path.resolve('./src') },
|
{ test: /\.js$/, loader: "babel", include: path.resolve('./src') },
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
|
output: {
|
||||||
|
devtoolModuleFilenameTemplate: function(info) {
|
||||||
|
// Reading input source maps gives only relative paths here for
|
||||||
|
// everything. Until I figure out how to fix this, this is a
|
||||||
|
// workaround.
|
||||||
|
// We use the relative resource path with any '../'s on the front
|
||||||
|
// removed which gives a tree with matrix-react-sdk and vector
|
||||||
|
// trees smashed together, but this fixes everything being under
|
||||||
|
// various levels of '.' and '..'
|
||||||
|
return info.resourcePath.replace(/^[\/\.]*/, '');
|
||||||
|
}
|
||||||
|
},
|
||||||
resolve: {
|
resolve: {
|
||||||
alias: {
|
alias: {
|
||||||
// alias any requires to the react module to the one in our path, otherwise
|
// alias any requires to the react module to the one in our path, otherwise
|
||||||
|
|
Loading…
Reference in a new issue