https://github.com/njzydark/mini-react-refresh-webpack-plugin
A mini webpack plugin for react refresh
https://github.com/njzydark/mini-react-refresh-webpack-plugin
react-refresh webpack-plugin
Last synced: 7 months ago
JSON representation
A mini webpack plugin for react refresh
- Host: GitHub
- URL: https://github.com/njzydark/mini-react-refresh-webpack-plugin
- Owner: njzydark
- License: mit
- Created: 2021-08-08T08:48:27.000Z (over 4 years ago)
- Default Branch: main
- Last Pushed: 2022-03-11T14:55:05.000Z (almost 4 years ago)
- Last Synced: 2025-08-08T20:01:56.510Z (7 months ago)
- Topics: react-refresh, webpack-plugin
- Language: TypeScript
- Homepage:
- Size: 79.1 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# mini-react-refresh-webpack-plugin
A mini webpack plugin for react refresh
> This plugin is based on [https://github.com/maisano/react-refresh-plugin](https://github.com/maisano/react-refresh-plugin)
## Motivation
When I use this plugin [pmmmwh/react-refresh-webpack-plugin](https://github.com/pmmmwh/react-refresh-webpack-plugin) in my project [chrome-extension-boilerplate](https://github.com/njzydark/chrome-extension-boilerplate), I meet this problem [issues/399](https://github.com/pmmmwh/react-refresh-webpack-plugin/issues/399), It took me a long time to solve this problem on the original repository, and finally I realized I should make a separate version to meet my later needs, such as excluding specific entries, so this version was born
## Usage
```bash
npm i -D @njzy/mini-react-refresh-webpack-plugin
```
webpack config:
```ts
import { MiniReactRefreshWebpackPlugin } from '@njzy/mini-react-refresh-webpack-plugin';
...
plugins: [new MiniReactRefreshWebpackPlugin()]
...
```
**PS:** No need to set `react-refresh/babel`
## Thanks
- [maisano/react-refresh-plugin](https://github.com/maisano/react-refresh-plugin)
- [pmmmwh/react-refresh-webpack-plugin](https://github.com/pmmmwh/react-refresh-webpack-plugin)
- [react-refresh](https://github.com/facebook/react/tree/main/packages/react-refresh/src)