ActionProperty

public class ActionProperty<T> : WriteOnlyProperty<T>

A convenience form of WriteOnlyProperty that allows a given function to be called whenever a new value is delivered through a binding. This allows for use of the ~~> operator that allows for setting up a binding between a UI control that produces momentary events (e.g. UIButton clicks) and an ActionProperty that wraps an event handler.

  • Undocumented

    Declaration

    Swift

    public init(_ action: @escaping (T) -> Void)