Loading

Waiting, said one way everywhere: inline, for the page, or as a bar. Write no spinner markup of your own.

Example

Loading orders
tsx
<Stack gap="md">
  <Loading message="Loading orders" />
  <Stack direction="row" gap="md" align="center">
    <Spinner size={20} label="Working" />
    <BlockLoader label="Syncing" />
  </Stack>
  <BarLoader label="Uploading" />
</Stack>

Usage

Pages are built on the server: import the tags from @dash/server and return the tree. The browser runtime draws it.
tsx
import { Loading, Spinner, BarLoader, BlockLoader, Stack } from "@dash/server";

Props

LoadingProps

Prop
Type
Description
messagestring
showSpinnerboolean
variant"inline" | "page" | "bar"`inline` (default) sits in the flow, `page` fills the space as a first load, `bar` is a thin progress bar fixed to the top of the screen.
delaynumberMilliseconds to wait before appearing (default: the framework's pending delay).

SpinnerProps

Prop
Type
Description
sizenumber
colorstring
labelstringNames the spinner for assistive technology; without it the spinner is decorative.
PreviousSidebar
On this page