DeweyReed / Theme

🎨 An Experimental Theme Engine for Android
Apache License 2.0
93 stars 6 forks source link

Jetpack Compose is a better way to provide dynamic theming. #8

Open DeweyReed opened 5 years ago

DeweyReed commented 5 years ago

After playing around with Jetpack Compose, I find that it supports changing view colors through color int instead of styles out of box. By the time of its stable release, this library may be replaced and deprecated.

ianrumac commented 4 years ago

Why so?

Most apps won't use compose in production for at least 2-3 years, and they mostly won't translate their codebases. And making an API that can be used with both compose and non-compose will be a great way to extend this library's lifecycle when the time comes :)

DeweyReed commented 4 years ago

@ianrumac This library is experimental and fragile and heavily depends on material-components-android. If you use this library in the production, you have to prepare to maintain the code every release of Android or material-components-android because everything will be changed. Besides, compound views like custom views or MaterialDateTimePicker are very hard to be tinted unless we deeply hook into Android Resources and View system, which makes the libary more fragile.

Since Jetpack Compose's able to do the work, I'll leave the job to it when the time is ready.