CommandKitHMREvent
CommandKitHMREvent
Represents an HMR event in CommandKit.
Signature
interface CommandKitHMREvent {
event: HMREventType;
path: string;
changeType?: HMREventChangeType;
accept: () => void;
preventDefault: () => void;
}
event
property
The type of HMR event.
path
property
stringThe path associated with the HMR event.
changeType
property
The original filesystem change type that triggered this HMR event.
accept
property
() => voidAccepts the HMR event, indicating that it has been handled. This prevents further processing of the event.
preventDefault
property
() => voidPrevents the default action for the HMR event. This can be used to stop further processing of the event.