useKeyboard( options?: KeyboardOptions,): { cleanup: () => void; getLayout: () => Promise<any>; isKeyActive: (code: string) => boolean; lock: (keyCodes?: string[]) => Promise<void>; unlock: () => void; get state(): KeyboardState; subscribe(callback: (state: KeyboardState) => void): () => boolean;} Parameters
- options: KeyboardOptions = {}
Returns {
cleanup: () => void;
getLayout: () => Promise<any>;
isKeyActive: (code: string) => boolean;
lock: (keyCodes?: string[]) => Promise<void>;
unlock: () => void;
get state(): KeyboardState;
subscribe(callback: (state: KeyboardState) => void): () => boolean;
}