build(webpack): using the original react refresh plugin
This commit is contained in:
parent
5a07ccae41
commit
64ea28607a
3 changed files with 378 additions and 411 deletions
|
@ -77,14 +77,14 @@
|
|||
"@babel/preset-react": "^7.7.4",
|
||||
"@babel/preset-typescript": "^7.10.1",
|
||||
"@hsjs/react-refresh-webpack-plugin": "^0.1.3",
|
||||
"@pmmmwh/react-refresh-webpack-plugin": "^0.2.0",
|
||||
"@pmmmwh/react-refresh-webpack-plugin": "^0.4.2",
|
||||
"@types/invariant": "^2.2.33",
|
||||
"@types/jest": "^26.0.9",
|
||||
"@types/lodash-es": "^4.17.3",
|
||||
"@types/react": "^16.9.48",
|
||||
"@types/react-dom": "^16.9.8",
|
||||
"@typescript-eslint/eslint-plugin": "^3.10.1",
|
||||
"@typescript-eslint/parser": "^3.10.1",
|
||||
"@typescript-eslint/eslint-plugin": "^4.0.1",
|
||||
"@typescript-eslint/parser": "^4.0.1",
|
||||
"autoprefixer": "^9.8.6",
|
||||
"babel-eslint": "10.x",
|
||||
"babel-loader": "^8.0.5",
|
||||
|
@ -123,7 +123,7 @@
|
|||
"style-loader": "^1.2.1",
|
||||
"terser-webpack-plugin": "^4.1.0",
|
||||
"ts-loader": "^8.0.3",
|
||||
"typescript": "^3.9.7",
|
||||
"typescript": "^4.0.2",
|
||||
"webpack": "^4.44.1",
|
||||
"webpack-bundle-analyzer": "^3.6.0",
|
||||
"webpack-cli": "^3.3.12",
|
||||
|
|
|
@ -8,7 +8,7 @@ const { CleanWebpackPlugin } = require('clean-webpack-plugin');
|
|||
const ForkTsCheckerWebpackPlugin = require('fork-ts-checker-webpack-plugin');
|
||||
const ForkTsCheckerNotifierWebpackPlugin = require('fork-ts-checker-notifier-webpack-plugin');
|
||||
const MiniCssExtractPlugin = require('mini-css-extract-plugin');
|
||||
const ReactRefreshWebpackPlugin = require('@hsjs/react-refresh-webpack-plugin');
|
||||
const ReactRefreshWebpackPlugin = require('@pmmmwh/react-refresh-webpack-plugin');
|
||||
|
||||
const pkg = require('./package.json');
|
||||
|
||||
|
@ -74,7 +74,11 @@ const plugins = [
|
|||
// and we don't need locale stuff in moment
|
||||
new webpack.IgnorePlugin(/^\.\/locale$/, /moment$/),
|
||||
// https://github.com/pmmmwh/react-refresh-webpack-plugin
|
||||
isDev ? new ReactRefreshWebpackPlugin({ disableRefreshCheck: true }) : false,
|
||||
isDev
|
||||
? new ReactRefreshWebpackPlugin({
|
||||
overlay: { sockIntegration: 'whm' },
|
||||
})
|
||||
: false,
|
||||
// isDev ? false : new webpack.HashedModuleIdsPlugin(),
|
||||
isDev ? false : cssExtractPlugin,
|
||||
isDev ? false : bundleAnalyzerPlugin,
|
||||
|
|
Loading…
Reference in a new issue