Contents

addItem(_:)

Adds a dynamic item to the dynamic item behavior’s item array.

Declaration

func addItem(_ item: any UIDynamicItem)

Parameters

  • item:

    The dynamic item to add to the item array.

Discussion

You can add a dynamic item to one or more dynamic item behaviors. For example, you could add a dynamic item to one dynamic item behavior to configure the item’s elasticity and to a second dynamic item behavior to configure its density. This is especially useful when you are defining custom, combined behaviors for your dynamic items.

See Also

Initializing and managing a dynamic item behavior