Table

A responsive table component.

A list of your recent invoices.
InvoiceStatusMethodAmount
INV001PaidCredit Card$250.00
INV002PendingPayPal$150.00
INV003UnpaidBank Transfer$350.00
INV004PaidPaypal$450.00
INV005PaidCredit Card$550.00
INV006PendingBank Transfer$200.00
INV007UnpaidCredit Card$300.00
Total$2,500.00

Anatomy

Import all parts and piece them together.

use leptos::prelude::*;
use singlestage::table::*;

#[component]
pub fn TableAnatomy() -> impl IntoView {
    view! {
        <Table>
            <TableCaption />
            <TableHeader>
                <TableRow>
                    <TableHead />
                </TableRow>
            </TableHeader>
            <TableBody>
                <TableRow>
                    <TableCell />
                </TableRow>
            </TableBody>
            <TableFooter>
                <TableRow>
                    <TableCell />
                </TableRow>
            </TableFooter>
        </Table>
    }
}

API Reference

Table

Contains all the part of a table component.

Implements global attributes.

TableBody

The table's body element.

Implements global attributes.

TableCaption

The table's caption element.

Implements global attributes.

TableCell

A table cell element.

Implements global and td attributes.

TableFooter

The table's footer element.

Implements global attributes.

TableHead

A table head element.

Implements global and th attributes.

TableHeader

The table's header element.

Implements global attributes.

TableRow

A table row element.

Implements global attributes.