MCPcopy Create free account
hub / github.com/GCWing/BitFun / dispatchKey

Function dispatchKey

src/web-ui/src/infrastructure/debug/useDebugInspector.test.tsx:39–47  ·  view source on GitHub ↗
(init: KeyboardEventInit)

Source from the content-addressed store, hash-verified

37}
38
39function dispatchKey(init: KeyboardEventInit): KeyboardEvent {
40 const event = new KeyboardEvent('keydown', {
41 bubbles: true,
42 cancelable: true,
43 ...init,
44 });
45 document.body.dispatchEvent(event);
46 return event;
47}
48
49describe('useDebugInspector', () => {
50 let container: HTMLDivElement;

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected