Remove React HMR (#21607)

This commit is contained in:
Robin 2022-03-30 11:57:26 -04:00 committed by GitHub
parent f029b68ad4
commit 5077157282
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 1 additions and 54 deletions

View file

@ -8,7 +8,6 @@ const MiniCssExtractPlugin = require('mini-css-extract-plugin');
const TerserPlugin = require('terser-webpack-plugin');
const OptimizeCSSAssetsPlugin = require('optimize-css-assets-webpack-plugin');
const HtmlWebpackInjectPreload = require('@principalstudio/html-webpack-inject-preload');
const ReactRefreshWebpackPlugin = require('@pmmmwh/react-refresh-webpack-plugin');
const SentryCliPlugin = require("@sentry/webpack-plugin");
dotenv.config();
@ -242,9 +241,6 @@ module.exports = (env, argv) => {
loader: 'babel-loader',
options: {
cacheDirectory: true,
plugins: [
useHMR && require.resolve('react-refresh/babel'),
].filter(Boolean),
},
},
{
@ -624,7 +620,6 @@ module.exports = (env, argv) => {
new HtmlWebpackInjectPreload({
files: [{ match: /.*Inter.*\.woff2$/ }],
}),
useHMR && new ReactRefreshWebpackPlugin(fullPageErrors ? undefined : { overlay: { entry: false } }),
// upload to sentry if sentry env is present
process.env.SENTRY_DSN &&