Skip to content

Commit

Permalink
Bug that failed to repair at
Browse files Browse the repository at this point in the history
  • Loading branch information
dotos committed Nov 18, 2017
1 parent 6138237 commit 836473b
Show file tree
Hide file tree
Showing 7 changed files with 25 additions and 13 deletions.
2 changes: 1 addition & 1 deletion dist/Valine.min.js

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions dist/detect.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions dist/escape.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion docs/en/hexo.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ There are a number of hexo theme built-in valine comment system, more themes are
> [Open](https://github.com/ahonn/hexo-theme-even/pull/179) `v1.1.7`
## hexo-theme-Anatole
> [Open](https://github.com/Ben02/hexo-theme-Anatole/pull/25) `v1.1.7`
> [Merged](https://github.com/Ben02/hexo-theme-Anatole/pull/25) `v1.1.7`
## maupassant-hexo
> [Merged](https://github.com/tufu9441/maupassant-hexo/pull/331) `latest`
Expand Down
2 changes: 1 addition & 1 deletion docs/hexo.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
> [Open](https://github.com/ahonn/hexo-theme-even/pull/179) `v1.1.7`
## hexo-theme-Anatole
> [Open](https://github.com/Ben02/hexo-theme-Anatole/pull/25) `v1.1.7`
> [Merged](https://github.com/Ben02/hexo-theme-Anatole/pull/25) `v1.1.7`
## maupassant-hexo
> [Merged](https://github.com/tufu9441/maupassant-hexo/pull/331) `latest`
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "valine",
"version": "1.1.8-beta6",
"version": "1.1.8-beta7",
"description": "A simple comment system based on Leancloud.",
"main": "/src/Valine.js",
"author": "xCss <[email protected]> (https://github.com/xCss)",
Expand Down
28 changes: 19 additions & 9 deletions webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,8 @@ var BUILD_PATH = path.resolve(ROOT_PATH, 'dist');
var plugins = [];

module.exports = env => {
let dev = env && env.dev || false
var dev = env && env.dev || false
if (!dev) {
console.log(1)
plugins.push(
new webpack.optimize.UglifyJsPlugin({
// 最紧凑的输出
Expand All @@ -29,28 +28,39 @@ module.exports = env => {
})
);
plugins.push(new webpack.LoaderOptionsPlugin({minimize:true}));
}else{
plugins.push(new webpack.NamedModulesPlugin())
plugins.push(new webpack.HotModuleReplacementPlugin())
}
plugins.push(new webpack.NamedModulesPlugin())
plugins.push(new webpack.HotModuleReplacementPlugin())
return {
entry: './src/' + libraryName + '.js',
entry: {
Valine:'./src/Valine.js',
detect:'./src/detect.js',
escape:'./src/escape.js'
},
output: {
path: BUILD_PATH,
filename: libraryName + '.min.js',
library: libraryName,
filename: '[name].min.js',
library: '[name]',
libraryTarget: 'umd',
umdNamedDefine: true
},

devtool: 'source-map',
devtool: 'cheap-module-source-map',

devServer: {
hot:true,
port: 8088,
inline:true,
progress:true,
host:'0.0.0.0',
publicPath: "/dist/"
publicPath: "/dist/",
historyApiFallback:true,
stats:'errors-only', //只在发生错误时输出
overlay:{ //当有编译错误或者警告的时候显示一个全屏overlay
errors:true,
warnings:true,
}
},

module: {
Expand Down

0 comments on commit 836473b

Please sign in to comment.