Slide 25
Slide 25 text
Usage: Higher Order Functions
// We want
fragmentManager.load {
it.replace(R.id.home_content, MyFragment.newInstance())
}
// Old way
val trans = fragmentManager.beginTransaction()
trans.replace(R.id.home_content, MyFragment.newInstance())
trans.commit()