import { ExtensionPriority , KeyBindingCommandFunction , KeyBindingNames , KeymapExtension , LiteralUnion , } from '@remirror/core' ; import { useExtension } from '@remirror/react-core' ; remarks export function useKeymap ( name , handler , priority = ExtensionPriority . Medium ) { useExtension ( KeymapExtension , ( { addCustomHandler } ) => addCustomHandler ( 'keymap' , [ priority , { [ name ] : handler } ] ) , [ priority , name , handler ] ) ; }