I'm used to putting any of viewWillAppearand viewDidLoad, it's normal until you find out. However, I think there should be some rules that determine when to put in viewWillAppearand when to put in viewDidLoad?
viewWillAppear
viewDidLoad
The simple rule that I use is this. viewDidLoad- this is when presentation resources are loaded. No image has been drawn yet. Therefore, calculations and code regarding geometry and visual representations should not be specified here. They must be in the viewWillAppearor method viewDidAppear.
viewDidAppear
ViewWillAppear can also be called multiple times
viewWillAppear , . ( , ). , .
, , , , .
viewDidLoad: .
viewWillAppear:
viewDidLoad - , . viewWillAppear , . , viewDidLoad - , UILabel. , , , , , iPod , "Now Playing", .
UILabel
, , . viewDidLoad viewWillAppear, , - , . , . , ( - ?), . , , Twitter. , Twitterrific, "..." , .