brianegan / bansa

A state container for Java & Kotlin, inspired by Redux & Elm
MIT License
444 stars 29 forks source link

Manage global Store in an Android application #27

Closed sunilson closed 6 years ago

sunilson commented 6 years ago

Hi,

I am currently learning to implement a small Android app with this library, but I am unsure where you would put the Store. Should there really be an application wide store Singleton and how would I handle orientation changes or the Android system killing the process and saving/restoring the state? Or is it better to put the store inside the ViewModel of the Android Architecture Components?

Thanks for your input!

brianegan commented 6 years ago

Unfortunately, I'm not too sure, and I'd actually recommend against using this lib. I'm not actively maintaining this project any longer and I've moved away from Android development over the past year.

A better alternative would be something like Reduks which has a built-in solution to that problem.

sunilson commented 6 years ago

Ok, thanks for your answer!