Skip to main content

render

Scroll mode, column width, and card/column virtualization settings. Pure render concerns.

Usage

render?: RenderConfig;
FieldTypeDefaultDescription
columnScrollbooleantruetrue: each column scrolls independently (classic Trello). false: the whole board shares one vertical scrollbar with sticky column headers.
fixedColumnWidthbooleantruetrue: every column is a fixed 280px. false: columns share the viewport width equally, with a 240px minimum.
virtualizeCardsbooleanfalseRenders only the visible card slice per column.
virtualizeColumnsbooleanfalseColumn shells stay mounted, but off-screen columns skip rendering card content.
estimatedCardHeightnumber80Height estimate (in pixels) for unmeasured cards.
cardOverscannumber5Extra cards rendered above and below the visible window as a scroll buffer.
columnOverscannumber1Extra columns rendered before and after the horizontal viewport.

All fields are optional. Omitted fields use their defaults.

Example

Default behavior (per-column scroll, fixed-width columns, no virtualization):

<Kanban :cards="cards" :columns="columns" />

Flex columns that share the viewport width:

<Kanban
:cards="cards"
:columns="columns"
:render="{ fixedColumnWidth: false }"
/>

Board-wide scroll with sticky headers:

<Kanban
:cards="cards"
:columns="columns"
:render="{ columnScroll: false }"
/>

Flex columns with board-wide scroll:

<Kanban
:cards="cards"
:columns="columns"
:render="{ columnScroll: false, fixedColumnWidth: false }"
/>

Card virtualization for large datasets:

<Kanban
:cards="cards"
:columns="columns"
:render="{
virtualizeCards: true,
estimatedCardHeight: 96,
cardOverscan: 8,
}"
/>

Full virtualization (cards and columns):

<Kanban
:cards="cards"
:columns="columns"
:render="{
virtualizeCards: true,
virtualizeColumns: true,
estimatedCardHeight: 96,
}"
/>