setRightBarButton(_:animated:)
Sets the custom bar button item, optionally animating the transition to the view.
Declaration
func setRightBarButton(_ item: UIBarButtonItem?, animated: Bool)Parameters
Discussion
If two navigation items have the same custom left or right bar button items, those bar button items remain stationary during the transition when the navigation item is pushed or popped.