diff --git a/build/config.js b/build/config.js index e6dab6b..1ff9967 100644 --- a/build/config.js +++ b/build/config.js @@ -3,7 +3,7 @@ import path from 'path'; const config = { projectRoot: path.resolve(__dirname, '../'), rootPath: path.resolve(__dirname, '../dist'), - nodePath: path.resolve(__dirname, '../node_modules'), + nodePath: path.resolve(__dirname, '../../node_modules'), docsPath: 'docs', indexPath: 'docs/index.html', publicPath: '/', diff --git a/build/webpack/dev.js b/build/webpack/dev.js index b464a26..d7ceb0b 100644 --- a/build/webpack/dev.js +++ b/build/webpack/dev.js @@ -2,6 +2,7 @@ import webpack from 'webpack'; import merge from 'webpack-merge'; import HtmlWebpackPlugin from 'html-webpack-plugin'; import baseWebpackConfig from './base'; +import config from '../config'; Object.keys(baseWebpackConfig.entry).forEach((name) => { baseWebpackConfig.entry[name] = ['./build/server/client'].concat(baseWebpackConfig.entry[name]); @@ -10,6 +11,7 @@ Object.keys(baseWebpackConfig.entry).forEach((name) => { export default merge(baseWebpackConfig, { devtool: '#inline-source-map', plugins: [ + new webpack.WatchIgnorePlugin([config.nodePath]), new webpack.HotModuleReplacementPlugin(), new webpack.NoErrorsPlugin(), new HtmlWebpackPlugin({