Merge pull request #1277 from vector-im/rav/no_parse_languages
Tell webpack not to parse the highlight.js languages
This commit is contained in:
commit
f52a1cf311
|
@ -14,7 +14,14 @@ module.exports = {
|
||||||
{ test: /\.js$/, loader: "babel", include: path.resolve('./src') },
|
{ test: /\.js$/, loader: "babel", include: path.resolve('./src') },
|
||||||
// css-raw-loader loads CSS but doesn't try to treat url()s as require()s
|
// css-raw-loader loads CSS but doesn't try to treat url()s as require()s
|
||||||
{ test: /\.css$/, loader: ExtractTextPlugin.extract("css-raw-loader") },
|
{ test: /\.css$/, loader: ExtractTextPlugin.extract("css-raw-loader") },
|
||||||
]
|
],
|
||||||
|
noParse: [
|
||||||
|
// don't parse the languages within highlight.js. They cause stack
|
||||||
|
// overflows (https://github.com/webpack/webpack/issues/1721), and
|
||||||
|
// there is no need for webpack to parse them - they can just be
|
||||||
|
// included as-is.
|
||||||
|
/highlight\.js\/lib\/languages/,
|
||||||
|
],
|
||||||
},
|
},
|
||||||
output: {
|
output: {
|
||||||
devtoolModuleFilenameTemplate: function(info) {
|
devtoolModuleFilenameTemplate: function(info) {
|
||||||
|
|
Loading…
Reference in New Issue