MCPcopy Create free account
hub / github.com/codeaashu/claude-code / stylesEqual

Function stylesEqual

src/ink/output.ts:534–543  ·  view source on GitHub ↗
(a: AnsiCode[], b: AnsiCode[])

Source from the content-addressed store, hash-verified

532}
533
534function stylesEqual(a: AnsiCode[], b: AnsiCode[]): boolean {
535 if (a === b) return true // Reference equality fast path
536 const len = a.length
537 if (len !== b.length) return false
538 if (len === 0) return true // Both empty
539 for (let i = 0; i < len; i++) {
540 if (a[i]!.code !== b[i]!.code) return false
541 }
542 return true
543}
544
545/**
546 * Convert a string with ANSI codes into styled characters with proper grapheme

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected