diff --git a/package.json b/package.json index aaf1a2b..6cb5fb8 100644 --- a/package.json +++ b/package.json @@ -30,7 +30,7 @@ "dompurify": "^0.8.9", "drop-stream": "^1.0.0", "duplex-maker": "^1.0.0", - "extract-loader": "^3.1.0", + "extract-loader": "^5.0.1", "file-loader": "^4.3.0", "getusermedia": "^2.0.0", "html-loader": "^0.5.5", @@ -40,8 +40,8 @@ "lodash.assign": "^4.2.0", "microphone-stream": "^3.0.5", "node-sass": "^4.9.3", - "raw-loader": "^0.5.1", - "regexp-replace-loader": "0.0.1", + "raw-loader": "^4.0.0", + "regexp-replace-loader": "1.0.1", "sass-loader": "^4.1.1", "stream-chunker": "^1.2.8", "subworkers": "^1.0.1", diff --git a/webpack.config.js b/webpack.config.js index 9f41a6e..ce2c591 100644 --- a/webpack.config.js +++ b/webpack.config.js @@ -1,3 +1,4 @@ +var theme = '../themes/MetroMumbleLight' var path = require('path'); module.exports = { @@ -29,12 +30,21 @@ module.exports = { { test: /\.html$/, use: [ - 'file-loader?name=[name].[ext]', - 'extract-loader', - 'html-loader?' + JSON.stringify({ - attrs: ['img:src', 'link:href'], - interpolate: 'require' - }) + { + loader: 'file-loader', + options: { 'name': '[name].[ext]' } + }, + { + loader: "extract-loader" + }, + { + loader: 'html-loader', + options: { + attrs: ['img:src', 'link:href'], + //interpolate: 'require', + root: theme + } + } ] }, { @@ -46,17 +56,21 @@ module.exports = { ] }, { + type: 'javascript/auto', test: /manifest\.json$|\.xml$/, use: [ 'file-loader', 'extract-loader', - 'regexp-replace-loader?' + JSON.stringify({ - match: { - pattern: "#require\\('([^']*)'\\)", - flags: 'g' - }, - replaceWith: '"+require("$1")+"' - }), + { + loader: 'regexp-replace-loader', + options: { + match: { + pattern: "#require\\('([^']*)'\\)", + flags: 'g' + }, + replaceWith: '"+require("$1")+"' + } + }, 'raw-loader' ] },