Тёмный

How to use Flutter Navigator 2.0? | Warning: it's complicated 

Learn App Code
Подписаться 19 тыс.
Просмотров 32 тыс.
50% 1

Опубликовано:

 

21 окт 2024

Поделиться:

Ссылка:

Скачать:

Готовим ссылку...

Добавить в:

Мой плейлист
Посмотреть позже
Комментарии : 77   
@kumarvishalben
@kumarvishalben 3 года назад
0:35 Forking ohh.... Okay
@rydmike
@rydmike 4 года назад
Thanks for this simple and approachable intro to Nav2. As noticed and commented, it is a lot of boilerplate indeed. Reason for that is to enable building navigators for much more complicated cases. For basic stack push/pop and its named variant, Nav1 or packages based on it to even simplify it (eg autoroute, fluro, get) are still very good alternatives. I am looking forward to seeing packages that make using Nav2 simpler and less boilerplaty for some specific more advanced use cases, often related to Web and Desktop navigation and their seamless transition to phone sized navigation. Not only url handling, but eg inserting master/child view page as poppable page when you resize the screen to phone size. Totally doable now that you can easily control the page stack.
@LearnFlutterCode
@LearnFlutterCode 4 года назад
No problem. It is a lot of boilerplate. And I would agree that it is for more complicated cases
@essli9430
@essli9430 5 месяцев назад
Bro you have a such great personality and your explanation is on the point and made the things so easy to be absorbed thanks bro
@chordfunc3072
@chordfunc3072 3 года назад
Not a fan of how most people do navigation... I tend to hide the navigation logic inside the page you are navigating to So when navigating I just call a async handler: final result = await BookPage.navigate(context,book); Then I can handle the result of the popped page in a linear fashion. I think people are overcomplicating navigation... Thanks for the video, nice introduction to the new navigator
@TrutleKingAvenger
@TrutleKingAvenger 3 года назад
Great video, it was clear and simply. I was able to get the main concept of the nav. Keep up the great work!!👍🏿👍🏿
@LearnFlutterCode
@LearnFlutterCode 3 года назад
Glad it helps!
@serverleung5861
@serverleung5861 2 года назад
I really like your method to explain and share in flutter learning (in many of your videos), put it in real life case to make me more easy to understand the logic inside of coding, great works and thanks!
@toplevelracing
@toplevelracing 3 года назад
What extension of vscode do you use to mark code blocks with white lines? Thanks 🙂
@kanybekmomukeev4116
@kanybekmomukeev4116 2 года назад
Same here
@AamirKhan-zy5yt
@AamirKhan-zy5yt 2 года назад
It's simple. * Open VS Code Settings (by pressing ctrl + ,) * In search bar, type "flutter UI guides" * Now TICK the checkbox - (preview flutter UI guides)
@gyhafmih3988
@gyhafmih3988 3 года назад
Tnank you very much... how do you zoom.. is it a shortcut? OR zooming is done while editing the video?
@JanaJaagruthi
@JanaJaagruthi 3 года назад
Hi, please Let me know if I add a new page support page totally unrelated to book and doesn't depend on _selected book . On a button click from anywhere take to support page . How can we navigate from any page to support page
@fenchai4892
@fenchai4892 4 года назад
those are some crazy boilerplate code. No thanks I'll keep using nav 1.0
@LearnFlutterCode
@LearnFlutterCode 4 года назад
I agree on this.
@arthurlima923
@arthurlima923 4 года назад
Is it possible that nav 1.0 will get "obsolete" and we will have to migrate to 2.0? Because I'm currently learning nav 1.0 from an online course.
@MaxweelFreitasdaSilva
@MaxweelFreitasdaSilva 4 года назад
​@@arthurlima923 Here in Brazil we belive that it will used just for packages to easely some tasks, and that the "normal user" will continue to use nav 1.0.
@arthurlima923
@arthurlima923 4 года назад
@@MaxweelFreitasdaSilva Opa, valeu cara! Sou Brasileiro também. Achei muito complexo o 2.0, espero que depois simplifiquem.
@MaxweelFreitasdaSilva
@MaxweelFreitasdaSilva 4 года назад
@@arthurlima923 Então, com vista nisso a comunidade (Flutterando) está empacotando o nav 2.0 dentro do Modular (pacote que te auxilia com gerenciamento de rotas e injeção de dependências)
@ac130kz
@ac130kz 4 года назад
I'll keep using auto_route instead :D
@prathamjaiswal2512
@prathamjaiswal2512 2 года назад
Very well explained Thanks
@midhunrajr372
@midhunrajr372 4 года назад
I am more interested the vs code extension you use to display the errors on the same line. What is the extension called?😁
@MrQooje2
@MrQooje2 4 года назад
Error Lens.
@ifrit1537
@ifrit1537 3 года назад
Does it mean tha the whole application is updated every time a navigation flow is executed?
@AngelCerveraClaudio
@AngelCerveraClaudio 3 года назад
I thumb up because it is easy to follow as a basic introduction to Navigator 2.0 The best moment is when he says: "Personally, I don't know exactly what onPopPage does". 😀 That comment tells how messy is the new Navigator API.
@Ainigma
@Ainigma 3 года назад
if you press a "BackButton" an event gets triggered to pop the current page. You can use that function to e.g. reload something.
@otaviogaiao8064
@otaviogaiao8064 3 года назад
Great video! Now, about the new navigator.... what a mess.
@LearnFlutterCode
@LearnFlutterCode 3 года назад
Tell me about it
@pierremarais7669
@pierremarais7669 3 года назад
Hi I love your videos, one question how do you get the 'red' comments in VSCode while you are typing in commnads please, thanks Pierre
@LearnFlutterCode
@LearnFlutterCode 3 года назад
I use the VSCode extension error lens.
@pierremarais7669
@pierremarais7669 3 года назад
@@LearnFlutterCode thanks a million, I'am looking for a demo on how to use an existing sql database in flutter app
@fazilkilicf
@fazilkilicf 3 года назад
hi sir, i enjoy watching your videos. I was going to ask something.Which theme are you using?
@LearnFlutterCode
@LearnFlutterCode 3 года назад
thanks. material theme.
@stellarcreed
@stellarcreed Год назад
sorry, but this approach of creating stateful widget instead of stateless just because of navigation 2.0, sucks.
@robertchan3037
@robertchan3037 4 года назад
Can I ask how I can set the initial route (at first launch of the app) to '/home' instead of '/'?
@LearnFlutterCode
@LearnFlutterCode 4 года назад
change initial route to '/'
@TheCass240
@TheCass240 3 года назад
What vscode plugin gives you the errors inline with the code?
@LearnFlutterCode
@LearnFlutterCode 3 года назад
Error Lens in VSCode extension
@rezaasgary1442
@rezaasgary1442 3 года назад
so basically it listens to the change of selected book automatically so we just change the state that's all that's kind of cool with state management its easy
@florianm5556
@florianm5556 3 года назад
I loved your video man it was cristal clear thanks Maybe a quick code recap would have been perfect at the end :)
@LearnFlutterCode
@LearnFlutterCode 3 года назад
Thanks for the idea!
@silentperson639
@silentperson639 4 года назад
Tutorial on how you made the books app it looks sick
@LearnFlutterCode
@LearnFlutterCode 4 года назад
I have not figure out how to make the tab bar, the one you see is fake XD. Other than that, most of the UI is achievable
@ibrahimmammadov9669
@ibrahimmammadov9669 2 года назад
0:35 you can follow along this tutorial by fu*king this project
@Algardraug
@Algardraug 3 года назад
Isn't the level of the audio extremely low?
@LearnFlutterCode
@LearnFlutterCode 3 года назад
Thanks for raising the issue. Will take note!
@srihariayapilla4233
@srihariayapilla4233 3 года назад
Make sure you 'fokk' the project !
@raheemadamboev
@raheemadamboev 2 года назад
yeah i wonder how i can 'fokk' projects, because there are so many i want to 'fokk'
@mahmoudeslami1145
@mahmoudeslami1145 4 года назад
I thick it's so f**kable in huge project . just use 1.0 version :)
@LearnFlutterCode
@LearnFlutterCode 4 года назад
It depends on your use case
@abdouseck4894
@abdouseck4894 3 года назад
yep
@alrawe261
@alrawe261 2 года назад
thanks for this video but i think old one is better
@mohammadzarkasi
@mohammadzarkasi 3 года назад
it really is complicated
@xabierperez
@xabierperez 3 года назад
thanks man!
@LearnFlutterCode
@LearnFlutterCode 3 года назад
Happy to help!
@trapeye3464
@trapeye3464 3 года назад
i dont understand lol.. how can u navigate nnext screen
@LearnFlutterCode
@LearnFlutterCode 3 года назад
No worries, a lot of people do not understand too.
@trapeye3464
@trapeye3464 3 года назад
@@LearnFlutterCode I understand this.. but I not understand that flutter web navigation.. if u kind can give example again that not have id book like a simple navigation to the next screen using navigation 2.0
@innerpeace2520
@innerpeace2520 3 года назад
in search of gold we lost Dimond be like :p
@АлександрИванов-ю8с8г
why it so complex now? for what?
@ExtraServingsBTS
@ExtraServingsBTS 4 года назад
Some Javascript developer must have snuck in a #@%&*(&d things up for us.
@LearnFlutterCode
@LearnFlutterCode 4 года назад
for simple cases, this method is too complex. however, if you want to have users change the url and sync with your flutter web app, then this is one way.
@ExtraServingsBTS
@ExtraServingsBTS 4 года назад
@@LearnFlutterCode For any case, this is too complex. I have no problem synchronizing my URL with the existing system & Fluro - and I'm currently exploring ways to get Fluro out of the mix. Someone must be feeling the need for some extra job security, needlessly complicating things so nobody can follow behind them. What ever happened to 'optimize for developer happiness'?
@Mark-og2cu
@Mark-og2cu 4 года назад
Audio is way too low!
@LearnFlutterCode
@LearnFlutterCode 4 года назад
Will take note
@EntnimraS
@EntnimraS 3 года назад
BRILLIANT!!!
@kasvith
@kasvith 3 года назад
Arguably the worst thing Flutter introduced so far
@iuniquekwt3177
@iuniquekwt3177 3 года назад
what's hard about this? XD
@LearnFlutterCode
@LearnFlutterCode 3 года назад
ever ry thing
Далее
These Are Too Smooth 😮‍💨
00:57
Просмотров 5 млн
10x Your Speed With Flutter
8:04
Просмотров 59 тыс.
Why Navigator 2.0 Sucks
12:56
Просмотров 14 тыс.
Learn Flutter Hooks and Maximize Your Code Reuse
10:36
I Remade YouTube From Scratch Using Just Bash
17:51
Просмотров 61 тыс.