The best practice on Android for creating a Fragment is to use a static factory method and pass arguments in a Bundle via setArguments()
Fragment
Bundle
setArguments()
inline fun newFragmentInstance(vararg params: Pair) = T::class.java.newInstance().apply { arguments = bundleOf(*params) }`
So it is used like that:
val fragment = newFragmentInstance("key" to value)
Credit
bundleOf() can be taken from Anko
bundleOf()