Marigold
Getting StartedFoundationsComponentsPatternsRecipesReleases
Discover new Tutorials!

Components

Overview

Application

MarigoldProvider
updated
RouterProvider
updated

Layout

Aside
Aspect
Breakout
Center
Columns
Container
Grid
Inline
Inset
Scrollable
Split
Stack
updated
Tiles

Form

Autocomplete
Button
updated
Calendar
Checkbox
ComboBox
DateField
DatePicker
Form
Multiselect
new
NumberField
Radio
SearchField
Select
Slider
Switch
TextArea
TextField
TimeField
new

Collection

SelectList
updated
Table
updated
Tag

Navigation

Accordion
Breadcrumbs
beta
Pagination
Tabs

Overlay

ContextualHelp
new
Dialog
Menu
Toast
beta
Tooltip
updated

Content

Badge
Body
Card
Divider
updated
Footer
Header
Headline
updated
Icon
updated
Image
Link
updated
List
updated
SectionMessage
SVG
updated
Text
updated
VisuallyHidden
updated
XLoader

Formatters

DateFormat
NumericFormat

Hooks and Utils

cn
cva
extendTheme
useAsyncListData
useListData
useResponsiveValue
useTheme

useAsyncListData

Hook that returns async data

We use the useAsyncListData hook from react-spectrum stately package. It extends the useListData which is also from react-spectrum.

It supports async loading, pagination, sorting and filtering. It also manages loading and error states, supports abortable requests and works with any data fetchig library or the built-in browser fetch API.

More information can be found in the react-spectrum documentation.

Import

import { useAsyncListData } from '@marigold/components';

Examples

Async Table

This is an example from the <Table> component. The data will be loaded asynchronously.

Preview
Code
NameHeightMassBirth Year
Last update: April 30, 2024
Build with 🥵, 🧡 and
v14.1.1