#5 || Passing Parameter To Route( Route Parameter) || Flutter Go Router Tutorial

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
welcome back everyone in this video I will discuss how to pass route parameters in go router here you can see I have defined two routes this one and this one my requirement is that to this route I will pass a route parameter and to achieve that here I need to put a slash and after that parameter name Let It Be name and I can receive this here how just like this name then I need to use state chart params after that the name that is this one so this name this name and this name must match after that this now let me move to profile as you can see to the Constructor of the profile I am passing this name so here I will create a string variable string name and here I will use this required this dot name and obviously this will be final now there is no need of putting this const here this const will not be there correct and this is the profile page now this name I will receive to the title of the app bar so here let me write welcome and after that dollar of name correct now this has a elevated button having the text as dashboard whenever I will hit here then I will move to the dashboard page similarly this dashboard page has a button profile and whenever I will hit on this button then I should move to the profile page so here I will write the code that is context dot go to which page I will move to the profile page correct so here I need to write slash of profile but while moving to this page I need to pass a route parameter as well so here I am declaring a string name Let It Be My Name That is Amar and after that here I will put slash then I will pass whatever is stored inside the name variable fine now let me do a hot restart let me show you the output so this dashboard page has a profile button once I click on this profile then you can see in the title bar welcome armor has been displayed and whenever I will hit on this dashboard then I am moving to the dashboard page this is how we can pass route parameter in go router don't forget to subscribe my channel thank you so much for watching
Info
Channel: Ripples Code
Views: 6,995
Rating: undefined out of 5
Keywords: flutter go router tutorial, go router complete tutorial, go router tutorial step by step, go router tutorial series, go router by ripples code, navigator 2.0 api flutter, go router tutorial for begineers, go router navigator 2.0, what is go router, latest go router tutorial, go router tutorial guide, advance go router tutorial, go router, route parameters, passing parameters to route in go router
Id: KTFM2-NzStI
Channel Id: undefined
Length: 3min 22sec (202 seconds)
Published: Sat Dec 17 2022
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.