slovnicki / beamer

A routing package built on top of Router and Navigator's pages API, supporting arbitrary nested navigation, guards and more.
MIT License
589 stars 130 forks source link

[Example] Botton navigation with Riverpod #601

Closed vduseev closed 1 year ago

vduseev commented 1 year ago

New example that implements bottom navigation using Riverpod.

Main things that this example demonstrates:

I was desperately looking for an example like this to implement in my app but failed to find one.

slovnicki commented 1 year ago

Hey @vduseev! :wave: Thanks for the PR and support :slightly_smiling_face:

This example looks great at a first glance. I'll take a closer look during the next few days and review it so we can merge.

vduseev commented 1 year ago

Hi @slovnicki, glad too hear that! Let me know if you think there is a room for improvement. I was mostly concerned about the need to use a constructor in a state object to pass initialization parameters to the nested router delegates.

vduseev commented 1 year ago

@slovnicki, Thank you very much for accepting the PR.

The use of constructors in a State object is something I've considered to be a bad practice, simply based on a general sentiment across the flutter industry. Which is why I've tried to avoid doing that, but, unfortunately, couldn't find a way around.

I'd be really happy to assist in implementation of the idea of storing persistent locations using Beamer. If you could, maybe, lay down your creative approach to this vision in a separate issue, so that all contributors could understand the concept better, that would be awesome. With Beamer being the best feature-rich navigation package at the moment, we'd have to be able to code an agnostic implementation of such capability. Which means no riverpod or provider ties. Probably a pure InheritedWidget based solution or something similar in spirit? I'd be glad to follow your direction in this regard.

slovnicki commented 1 year ago

@vduseev Thanks for the kind words and interest in contributing.

I plan to publish a somewhat lengthy roadmap to Beamer v2 where I'll describe a couple of new big features in separate issues and various improvements I have in mind.

Something always gets in my way so this roadmap has been postponed for some time now, but I feel confident to publish it by the end of this week. (edit: it will be done by 7.4. and officially announced on 10.4.)

I'll let you know when it's out 🙂

dleurs commented 1 year ago

Thank you @vduseev for your example, I was really looking for this !