rendererPaint backend; defaults to main-thread canvas and falls back there if a worker fails.
renderer?:"canvas"|"worker";
workerUrlURL of the worker renderer module (renderer: "worker"), as served to the BROWSER — the platform Worker constructor does not consult package exports, so a bare specifier like new URL("@sheetwrite/core/worker",…
workerUrl?: string |URL;
URL of the worker renderer module (`renderer: "worker"`), as served to the
BROWSER — the platform `Worker` constructor does not consult package
exports, so a bare specifier like `new URL("@sheetwrite/core/worker",
import.meta.url)` is NOT reliable. Either copy
`@sheetwrite/core/dist/worker.js` to your public assets and pass its URL
string (works everywhere), or use your bundler's dependency-worker import
if it has one (see `/docs/guides/worker-rendering/`). If omitted or the worker
can't be constructed, the grid falls back to the main-thread canvas
renderer and emits `renderer-fallback` once.
themeOverrides merged over the default theme and host CSS custom properties.
Host-owned client UX permission check. Servers must independently authorize
every submitted operation; this resolver is not an authentication boundary.
mutationPolicyAtomic rejects the transaction; partial skips denied operation objects.
mutationPolicy?:MutationPolicyModetype MutationPolicyMode = "atomic" | "partial";typeMutationPolicyMode="atomic"|"partial";typeMutationPolicyMode="atomic"|"partial";Atomic or partial handling for locally denied operations.API reference →;
transactionResourceLimitsOverrides inclusive operation-count and encoded-byte ceilings for every atomic mutation.
transactionResourceLimits?: Partial<TransactionResourceLimitsinterface TransactionResourceLimits {
maxOperations: number;
maxEncodedBytes: number;
}interfaceTransactionResourceLimits {maxOperations:number;maxEncodedBytes:number;}interfaceTransactionResourceLimits {maxOperations:number;maxEncodedBytes:number;}Public ceilings shared by transaction producers, persistence, transport, and replay. Limits measure the submitted operation array itself, not the logical cell area covered by compact operations.API reference →>;
renderersCustom cell renderers registered up front; also see Grid.defineCellRenderer.
renderers?: Record<string, CellRendererinterface CellRenderer {
canvas?(ctx: CanvasRenderingContext2D, c: CellPaintContext): void;
dom?(c: CellPaintContext): HTMLElement;
}interfaceCellRenderer {canvas?(ctx:CanvasRenderingContext2D, c:CellPaintContext):void;dom?(c:CellPaintContext):HTMLElement;}interfaceCellRenderer {canvas?(ctx:CanvasRenderingContext2D,c:CellPaintContext,):void;dom?(c:CellPaintContext,):HTMLElement;}Custom cell renderer hooks for the main-thread canvas or DOM overlay.API reference →>;
overscanRows rendered above/below the viewport to absorb fast scrolls.
overscan?: number;
minColumnsRender at least this many columns (empty padding columns past the data, like a spreadsheet).
minColumns?: number;
configBuilt-in UI controls; providing an object enables the toolbar unless toolbar is false.
config?:GridConfiginterface GridConfig {
toolbar?: boolean | ToolbarItem[];
bold?: boolean;
italic?: boolean;
align?: boolean;
textColor?: boolean;
fillColor?: boolean;
border?: boolean;
clearFormat?: boolean;
merge?: boolean;
sort?: boolean;
export?: boolean;
icons?: Partial<Record<ToolbarActionName, ToolbarIcon>>;
contextMenu?: boolean | ContextMenuItems;
undo?: boolean;
// … 4 more lines — see the API reference
}interfaceGridConfig {toolbar?:boolean|ToolbarItem[];bold?:boolean;italic?:boolean;align?:boolean;textColor?:boolean;fillColor?:boolean;border?:boolean;clearFormat?:boolean;merge?:boolean;sort?:boolean;export?:boolean;icons?:Partial<Record<ToolbarActionName, ToolbarIcon>>;contextMenu?:boolean|ContextMenuItems;undo?:boolean;// … 4 more lines — see the API reference}interfaceGridConfig {toolbar?:boolean|ToolbarItem[];bold?:boolean;italic?:boolean;align?:boolean;textColor?:boolean;fillColor?:boolean;border?:boolean;clearFormat?:boolean;merge?:boolean;sort?:boolean;export?:boolean;icons?:Partial<Record<ToolbarActionName,ToolbarIcon>>;// … 12 more lines — see the API reference}Toolbar / feature configuration. When config is set the built-in toolbar is shown; control flags default to true except the opt-in export flag.API reference →;
Declaration
View full TypeScript declaration
exportinterfaceGridOptions {
workbook:Workbookinterface Workbook {
sheets: Sheet[];
activeSheet: SheetId;
namedRanges?: NamedRangeSnapshot[];
}interfaceWorkbook {sheets:Sheet[];activeSheet:SheetId;namedRanges?:NamedRangeSnapshot[];}interfaceWorkbook {sheets:Sheet[];activeSheet:SheetId;namedRanges?:NamedRangeSnapshot[];}Live workbook schema containing ordered sheets and the active sheet ID.API reference →;
data?:ColumnarDatainterface ColumnarData {
rowCount: number;
columns: Record<string, ArrayLike<CellScalar | CellValue>>;
}interfaceColumnarData {rowCount:number;columns:Record<string, ArrayLike<CellScalar|CellValue>>;}interfaceColumnarData {rowCount:number;columns:Record<string,ArrayLike<CellScalar|CellValue>>;}Eager column-oriented values used to initialize a sheet.API reference →;
mutationPolicy?:MutationPolicyModetype MutationPolicyMode = "atomic" | "partial";typeMutationPolicyMode="atomic"|"partial";typeMutationPolicyMode="atomic"|"partial";Atomic or partial handling for locally denied operations.API reference →;
transactionResourceLimits?:Partial<TransactionResourceLimitsinterface TransactionResourceLimits {
maxOperations: number;
maxEncodedBytes: number;
}interfaceTransactionResourceLimits {maxOperations:number;maxEncodedBytes:number;}interfaceTransactionResourceLimits {maxOperations:number;maxEncodedBytes:number;}Public ceilings shared by transaction producers, persistence, transport, and replay. Limits measure the submitted operation array itself, not the logical cell area covered by compact operations.API reference →>;
renderers?:Record<string, CellRendererinterface CellRenderer {
canvas?(ctx: CanvasRenderingContext2D, c: CellPaintContext): void;
dom?(c: CellPaintContext): HTMLElement;
}interfaceCellRenderer {canvas?(ctx:CanvasRenderingContext2D, c:CellPaintContext):void;dom?(c:CellPaintContext):HTMLElement;}interfaceCellRenderer {canvas?(ctx:CanvasRenderingContext2D,c:CellPaintContext,):void;dom?(c:CellPaintContext,):HTMLElement;}Custom cell renderer hooks for the main-thread canvas or DOM overlay.API reference →>;
overscan?:number;
minColumns?:number;
config?:GridConfiginterface GridConfig {
toolbar?: boolean | ToolbarItem[];
bold?: boolean;
italic?: boolean;
align?: boolean;
textColor?: boolean;
fillColor?: boolean;
border?: boolean;
clearFormat?: boolean;
merge?: boolean;
sort?: boolean;
export?: boolean;
icons?: Partial<Record<ToolbarActionName, ToolbarIcon>>;
contextMenu?: boolean | ContextMenuItems;
undo?: boolean;
// … 4 more lines — see the API reference
}interfaceGridConfig {toolbar?:boolean|ToolbarItem[];bold?:boolean;italic?:boolean;align?:boolean;textColor?:boolean;fillColor?:boolean;border?:boolean;clearFormat?:boolean;merge?:boolean;sort?:boolean;export?:boolean;icons?:Partial<Record<ToolbarActionName, ToolbarIcon>>;contextMenu?:boolean|ContextMenuItems;undo?:boolean;// … 4 more lines — see the API reference}interfaceGridConfig {toolbar?:boolean|ToolbarItem[];bold?:boolean;italic?:boolean;align?:boolean;textColor?:boolean;fillColor?:boolean;border?:boolean;clearFormat?:boolean;merge?:boolean;sort?:boolean;export?:boolean;icons?:Partial<Record<ToolbarActionName,ToolbarIcon>>;// … 12 more lines — see the API reference}Toolbar / feature configuration. When config is set the built-in toolbar is shown; control flags default to true except the opt-in export flag.API reference →;