Hi. What is the suggested way to include a fragmen...
# anko
n
Hi. What is the suggested way to include a fragment in an anko layout? There is no
fragment
function in the DSL.
m
You can add fragments programmatically, using
beginTransaction()
and so on.
n
So I need to create a placeholder for my Fragment too? A
FrameLayout
?
m
You can add your fragment wherever you want, including Activity root —
android.R.id.content
.
n
@miha-x64 Well, I tried to add it inside an
alert
with
customView
, and it doesn’t seem to work. On a regular Activity it worked fine.