Skip to main content

# ModuleUnLoadingListener

    type ModuleUnLoadingListener = (params: {
      eventName: string;
      eventOptions?: Record<string, unknown>;
      eventParams: ModuleUnloadInfo;
      obj: IModule;
    }) => boolean;

event handler that handles module unload event

## Parameters​

### params​

event parameters

#### eventName​

`string`

event name

#### eventOptions?​

`Record`<`string`, `unknown`>

additional options related to the event

#### eventParams​

`ModuleUnloadInfo`

Module unload info

#### obj​

`IModule`

module object reference

## Returns​

`boolean`

true to allow module unload, false otherwise