Mavericks View Model Factory
interface MavericksViewModelFactory<VM : MavericksViewModel<S>, S : MavericksState>
Content copied to clipboard
Implement this on your ViewModel's companion object for hooks into state creation and ViewModel creation. For example, if you need access to the fragment or activity owner for dependency injection.
Functions
create
Link copied to clipboard
initial State
Link copied to clipboard
The initial state for the ViewModel. Override this if the initial state requires information from arguments, or the ViewModel owner. This function will take precedence over any secondary constructors defined in the state class, S.