79140869

Date: 2024-10-30 11:26:22
Score: 2.5
Natty:
Report link

Why you should use bloc

In my opinion you should use bloc for this app. Bloc pattern's main objective is to ensure code maintainability and extensibility for app that has multiple states.

Bloc pattern will give you the ability to easily mantain your code by providing a good separation between logic and presentation. It's also pretty easy to extend by adding new events or states.

The downside of using bloc is that you will produce a lot of boilerplate code but I think it will be worth it when you'll need to handle a lot differents states.

To better understand if Bloc are good for your case you can also check this articles:

Performance pitfalls

There are no heavy performance pitfalls if you handle blocs correctly. For example you should avoid using global bloc and use them only in the part of the widget tree in which they are needed.

Reasons:
  • Blacklisted phrase (1): this article
  • Long answer (-0.5):
  • No code block (0.5):
  • Starts with a question (0.5): Why you
  • Low reputation (1):
Posted by: Zan