Function: installWebpackHMR()
Imported from
@react-logic/diinstallWebpackHMR(
hot):void
Defined in: di/src/lib/hmr.ts:54
Wires the default adapter's reset into Webpack's HMR dispose hook. Webpack
fires this when this module is replaced; pair with module.hot.accept()
if you want it to fire on broader updates.
Parameters
hot
false | DisposableHot | undefined
Returns
void
Example
// main.tsx
import { installWebpackHMR } from '@react-logic/di';
installWebpackHMR(import.meta.webpackHot);