{"size": 683, "ext": "js", "max_stars_repo_path": "config/webpack.config.dev.js", "max_stars_repo_name": "vusui/webpack-mpa-cli", "max_stars_repo_stars_event_min_datetime": "2018-11-15T16:27:02.000Z", "max_stars_repo_stars_event_max_datetime": "2018-11-15T16:27:02.000Z", "max_issues_repo_path": "config/webpack.config.dev.js", "max_issues_repo_name": "vusui/webpack-mpa-cli", "max_issues_repo_issues_event_min_datetime": null, "max_issues_repo_issues_event_max_datetime": null, "max_forks_repo_path": "config/webpack.config.dev.js", "max_forks_repo_name": "vusui/webpack-mpa-cli", "max_forks_repo_forks_event_min_datetime": null, "max_forks_repo_forks_event_max_datetime": null}
{"max_stars_count": 1, "max_issues_count": null, "max_forks_count": null, "avg_line_length": 22.7666666667, "max_line_length": 53, "alphanum_fraction": 0.5827232796}
/**
 * 开发环境配置
 */
const webpack = require("webpack");
const path = require("path");
// 引入基础配置文件
const webpackBase = require("./webpack.config.base");
// 引入 webpack-merge 插件
const webpackMerge = require("webpack-merge");
// 引入配置文件
const config = require("./config");
// 合并配置文件
module.exports = webpackMerge(webpackBase, {
    // 插件
    plugins: [
        // new webpack.NamedModulesPlugin(),
        // new webpack.HotModuleReplacementPlugin(),
    ],
    // 配置 webpack-dev-server
    devServer: {
        // 项目根目录
        contentBase: config.distPath,
        hot: true,
        // 错误、警告展示设置
        overlay: {
            errors: true,
            warnings: true
        }
    }
});