Skip to main content

tab_view_customization

Function tab_view_customization 

Source
pub fn tab_view_customization(view: &ViewHandle) -> ViewHandle
Expand description

.tabViewCustomization(_:) with a live customization, not nil.

tab_view_customization_none passes nil, which is the “do not persist anything” case and the only one that needed no value. This builds a real TabViewCustomization and hands SwiftUI a binding to it, so the user’s reordering and hiding of tabs is kept — the whole point of the modifier.

The value lives in the binding’s closures for the life of the process: a customization SwiftUI can write back to has to outlive the call that made it, and there is nowhere else to put it.