# Type Alias Hook<K>

type Hook<K extends keyof HookEvents = keyof HookEvents> = {
callback: (data: HookEvents[K]) => void;
name: K;
}

#### Type Parameters

- K extends keyof HookEvents = keyof HookEvents

- Defined in jslib/src/lib/types/types.ts:2855

##### Index

### Properties

callback
name

## Properties

### callback

callback: (data: HookEvents[K]) => void

- Defined in jslib/src/lib/types/types.ts:2857

### name

name: K

- Defined in jslib/src/lib/types/types.ts:2856