This is my note for Udemy lesson: Advanced Android Bootcamp 2024.
First, check my previous note
Then in HomeFragment, do:
val bundle = bundleOf("user_name" to binding.editTextText.text.toString()) it.findNavController().navigate(R.id.action_homeFragment_to_secondFragment, bundle)
In SecondFragment, do:
val userName = arguments?.getString("user_name")