Created
November 24, 2019 08:10
-
-
Save user-mw/e4c2967fa8a9583c36e890860d8b4a3e to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public сlass HolderFragment extends Fragment { | |
// Other code | |
private ViewModelStore mViewModelStore = new ViewModelStore(); | |
public HolderFragment() { | |
setRetainInstance(true); | |
} | |
public ViewModelStore getViewModelStore() { | |
return mViewModelStore; | |
} | |
// Other code | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment