This commit is contained in:
syuilo
2018-02-15 23:07:19 +09:00
parent a215ef6680
commit a7601f7aa4
8 changed files with 55 additions and 70 deletions

View File

@@ -2,12 +2,30 @@
* Vue
*/
const constants = require('../../../src/const.json');
export default () => ({
test: /\.vue$/,
exclude: /node_modules/,
loader: 'vue-loader',
options: {
cssSourceMap: false,
preserveWhitespace: false
}
use: [{
loader: 'vue-loader',
options: {
cssSourceMap: false,
preserveWhitespace: false
}
}, {
loader: 'webpack-replace-loader',
options: {
search: '$theme-color',
replace: constants.themeColor,
attr: 'g'
}
}, {
loader: 'webpack-replace-loader',
query: {
search: '$theme-color-foreground',
replace: constants.themeColorForeground,
attr: 'g'
}
}]
});