Matthew Laser
01/25/2022, 3:22 PMiona bartishvili
01/25/2022, 3:25 PMMatthew Laser
01/25/2022, 3:26 PMiona bartishvili
01/25/2022, 3:27 PMMarcin Wisniowski
01/25/2022, 4:04 PMIan Lake
01/25/2022, 4:30 PMMatthew Laser
01/25/2022, 4:36 PM<http://R.layout.my|R.layout.my>_screen
directly into an Activity if I wanted to, but for most "real world" use cases, it'll be in my best interest to attach a fragment to that activity, which uses <http://R.layout.my|R.layout.my>_screen
inside of onCreateView
.
I'm trying to understand if the compose tutorials / docs are sticking @Composable
views directly into `Activity`'s setContentView
for simplicity of explanation or as a best practiceIan Lake
01/25/2022, 5:01 PMFragmentActivity
or Fragment
at all - you'd just use ComponentActivity
and setContent
directly. You'd still want to separate out the logic of each screen (either by using Navigation Compose or some other navigation system) into their own, separately testable/previewable composableEmre ERKAHRAMAN
01/26/2022, 12:04 PM