Initializer

init(content:)

Creates a list with the given content.

Declaration

init(@ViewBuilder content: () -> Content)
Available when SelectionValue is Never.

Parameters

content

The content of the list.

See Also

Creating a List

init<Data, ID, RowContent>(Data, id: KeyPath<Data.Element, ID>, rowContent: (Data.Element) -> RowContent)

Creates a list that identifies its rows based on a key path to the identifier of the underlying data.

init<Data, ID, RowContent>(Data, id: KeyPath<Data.Element, ID>, selection: Binding<Set<SelectionValue>>?, rowContent: (Data.Element) -> RowContent)

Creates a list that identifies its rows based on a key path to the identifier of the underlying data.

init<Data, ID, RowContent>(Data, id: KeyPath<Data.Element, ID>, selection: Binding<SelectionValue?>?, rowContent: (Data.Element) -> RowContent)

Creates a list that identifies its rows based on a key path to the identifier of the underlying data.

init<RowContent>(Range<Int>, rowContent: (Int) -> RowContent)

Creates a list that computes its views on demand over a constant range.

init<Data, RowContent>(Data, rowContent: (Data.Element) -> RowContent)

Creates a list that computes its rows on demand from an underlying collection of identifiable data.

init<RowContent>(Range<Int>, selection: Binding<Set<SelectionValue>>?, rowContent: (Int) -> RowContent)

Creates a list that computes its views on demand over a constant range.

init<RowContent>(Range<Int>, selection: Binding<SelectionValue?>?, rowContent: (Int) -> RowContent)

Creates a list that computes its views on demand over a constant range.

init<Data, RowContent>(Data, selection: Binding<Set<SelectionValue>>?, rowContent: (Data.Element) -> RowContent)

Creates a list that computes its rows on demand from an underlying collection of identifiable data.

init<Data, RowContent>(Data, selection: Binding<SelectionValue?>?, rowContent: (Data.Element) -> RowContent)

Creates a list that computes its rows on demand from an underlying collection of identifiable data.

init(selection: Binding<Set<SelectionValue>>?, content: () -> Content)

Creates a list with the given content that supports selecting multiple rows.

init(selection: Binding<SelectionValue?>?, content: () -> Content)

Creates a list with the given content that supports selecting a single row.