Something went wrong. Try again.
source dump of claude code forked from oppi.li/claude-code
Something went wrong. Try again.
354 B · 15 lines
TypeScript
at main
12345678910111213141516import { useContext } from 'react'import { type TerminalSize, TerminalSizeContext,} from 'src/ink/components/TerminalSizeContext.js'
export function useTerminalSize(): TerminalSize { const size = useContext(TerminalSizeContext)
if (!size) { throw new Error('useTerminalSize must be used within an Ink App component') }
return size}