SheetXL - v0.8.0-beta.9+sites.210.e2d420901
    Preparing search index...

    Function useFormulaViewAnchor

    • The shared formula-view spotlight source: while sheetView.isShowFormulas() is on, tracks the sheet's selection anchor and — when it sits on a formula cell — returns that formula's tokens and scoped reference ranges. Consumed by SheetCellLayer (suppress the anchor's plain tile text + overlay the colored FormulaCellRenderer) and SheetReferenceLayer (outline the references via the ranges picker), so the two always agree on what is spotlighted — and colors line up, both keying off referenceIndex.

      Parameters

      • sheet: ISheet
      • showFormulas: boolean
      • Optionaltoken: unknown

      Returns FormulaViewAnchor | null

      Re-renders on onSelectionChange only while enabled. The derivation is memoized on the anchor (the sdk selection's coords object is replaced only on a real change), so per-frame renders (scroll) never re-tokenize; token lets a caller bust it when cell CONTENT changed (e.g. the cells layer's visible-range cache token).