1
0
mirror of https://github.com/chinchang/web-maker.git synced 2025-07-30 18:20:15 +02:00

fix preact.config and add icon

This commit is contained in:
Kushagra Gour
2018-06-14 02:11:41 +05:30
parent df317d0dd4
commit 253f168f2c
2 changed files with 34 additions and 37 deletions

View File

@@ -11,7 +11,7 @@ import CopyWebpackPlugin from 'copy-webpack-plugin'
export default function (config, env, helpers) { export default function (config, env, helpers) {
if (env.isProd) { if (env.isProd) {
config.devtool = false; // disable sourcemaps config.devtool = false; // disable sourcemaps
}
config.plugins.push(new CopyWebpackPlugin([{ config.plugins.push(new CopyWebpackPlugin([{
context: `${__dirname}/src/assets`, context: `${__dirname}/src/assets`,
from: `*.*` from: `*.*`
@@ -36,18 +36,15 @@ export default function (config, env, helpers) {
} }
])); ]));
// let plugins = helpers.getPlugins();
// console.log(helpers.getPlugins(config));
const { const {
plugin plugin
} = helpers.getPluginsByName(config, 'SWPrecacheWebpackPlugin')[0]; } = helpers.getPluginsByName(config, 'SWPrecacheWebpackPlugin')[0];
console.log(plugin)
plugin.options.maximumFileSizeToCacheInBytes = 2900000; plugin.options.maximumFileSizeToCacheInBytes = 2900000;
const {
let {
index index
} = helpers.getPluginsByName(config, 'UglifyJsPlugin')[0] } = helpers.getPluginsByName(config, 'UglifyJsPlugin')[0]
config.plugins.splice(index, 1) config.plugins.splice(index, 1)
}
} }

BIN
webmaker/src/icon-128.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.3 KiB