initState() is the first method called after a widget is created. This is similar to onCreate() in Android or viewDidLoad() in iOS.
The first time the framework builds a widget, it calls didChangeDependencies() after initState(). It might call didChangeDependencies() again if your state object depends on an inherited widget that has changed.