Bloc: is it really necessary to change the interfaces all the time

Created on 5 Dec 2019  路  3Comments  路  Source: felangel/bloc

Hello, if the best library is becoming a problem, is it really necessary to change the interfaces all the time?
I appreciate the work, but this library is becoming a problem for me.

question

Most helpful comment

Changes to packages are always a bit annoying for anyone, but in order to polish a library change must happen. Surely you're not going to complain when you'll be able to write a time machine using 3 lines of code.

All 3 comments

Hi @gustavobrian 馃憢
Thanks for opening an issue!

Can you provide a bit more context? Is there a particular change(s) you鈥檙e referring to? Sorry for the inconvenience!

Changes to packages are always a bit annoying for anyone, but in order to polish a library change must happen. Surely you're not going to complain when you'll be able to write a time machine using 3 lines of code.

Closing for now since there isn't enough context for me to address this. I just want to add that you should specify versions in your pubspec like:

dependencies:
  flutter_bloc: ^2.0.0

This will ensure that you get all non-breaking updates but when v3.0.0 comes out you will not be forced to upgrade (it's up to you when to manually update the version in your pubspec to ^3.0.0).

If you just have something like:

dependencies:
  flutter_bloc:

or

dependencies:
  flutter_bloc: any

Then you might have breaking changes when you do a flutter packages get.

As @RollyPeres mentioned, the changes are all done in order to fix bugs or add features which ultimately should improve the developer experience. With that being said, you should never feel forced to upgrade. There's nothing wrong with specifying an exact version in your pubspec.yaml if you don't want to take any chances with upgrades.

dependencies:
  flutter_bloc: 2.0.0

In addition, if you're working on an app then it's recommended to check in your pubspec.lock to source control. This will ensure that everyone who pulls the code and runs a flutter packages get will have the same versions of the dependencies.

Hope that helps and feel free to add additional information and I'm happy to continue the conversation 馃憤

Was this page helpful?
0 / 5 - 0 ratings

Related issues

frankrod picture frankrod  路  3Comments

abinvp picture abinvp  路  3Comments

clicksocial picture clicksocial  路  3Comments

1AlexFix1 picture 1AlexFix1  路  3Comments

wheel1992 picture wheel1992  路  3Comments