Initializer

init(selection:columns:rows:)

Creates a table with the given columns and rows that supports selecting zero or one row.

Declaration 宣言

init(selection: Binding<Value.ID?>, columns: () -> Columns, rows: () -> Rows)
Available when Value is Rows.TableRowValue, Rows conforms to TableRowContent, Columns conforms to TableColumnContent, and Rows.TableRowValue is Columns.TableRowValue.

Parameters パラメータ

selection

A binding to the optional selected row id.

columns

The columns to display in the table.

rows

The rows to display in the table.

See Also 参照

Creating a Table from Columns and Rows