Just analyzed a pubspec one guy posted on Linkedin of his PAID flutter template :)
Let's review this pubspec.yaml file:
- auto_route: A navigation library with common issues related to templating. Currently, there's no ideal recommendation to replace it, but it's not great. Consider using go_router instead.
- awesome_flutter_extensions: While it might be useful, I don't recommend including it as a dependency in templates. Instead, add it manually if you find it beneficial in specific projects.
- collection: A great library! However, it's better to specify it under "any" versioning, along with other Flutter dependencies like meta, intl, and async.
- flutter_animate: This is a good choice.
- flutter_settings_ui: This library has been archived and only adds a settings screen. It's better to manually create your own settings screen for better control and flexibility.
- hive: This database is unsupported and problematic—avoid it at all costs. I recommend SQLite as a more stable alternative. More details here: https://lnkd.in/d5rGgdfQ.
- hooks: This is difficult to read and prone to errors. Instead, opt for using the lifecycle methods of a StatefulWidget.
- riverpod: A poor state management library with tight coupling, reliance on global variables, and side-effects. A better option would be to use bloc for state management and follow healthy dependency injection practices. More on this here: https://lnkd.in/dJKwbwsK and https://lnkd.in/dneDc5T7. Additional insights about riverpod can be found here: https://lnkd.in/deZpZH_C.
- logger: I'm not familiar with this one, but it’s often better to create your own custom logger, like the one in this template: https://lnkd.in/dha5d-UZ.
Good packages:
- mockito
- image_picker
- intl
- json_serializable
- freezed
- cached_network_image
By the way, I have my own template, that I recommend taking look as well https://lnkd.in/dz9FR5BG (it's free)
Let's review this pubspec.yaml file:
- auto_route: A navigation library with common issues related to templating. Currently, there's no ideal recommendation to replace it, but it's not great. Consider using go_router instead.
- awesome_flutter_extensions: While it might be useful, I don't recommend including it as a dependency in templates. Instead, add it manually if you find it beneficial in specific projects.
- collection: A great library! However, it's better to specify it under "any" versioning, along with other Flutter dependencies like meta, intl, and async.
- flutter_animate: This is a good choice.
- flutter_settings_ui: This library has been archived and only adds a settings screen. It's better to manually create your own settings screen for better control and flexibility.
- hive: This database is unsupported and problematic—avoid it at all costs. I recommend SQLite as a more stable alternative. More details here: https://lnkd.in/d5rGgdfQ.
- hooks: This is difficult to read and prone to errors. Instead, opt for using the lifecycle methods of a StatefulWidget.
- riverpod: A poor state management library with tight coupling, reliance on global variables, and side-effects. A better option would be to use bloc for state management and follow healthy dependency injection practices. More on this here: https://lnkd.in/dJKwbwsK and https://lnkd.in/dneDc5T7. Additional insights about riverpod can be found here: https://lnkd.in/deZpZH_C.
- logger: I'm not familiar with this one, but it’s often better to create your own custom logger, like the one in this template: https://lnkd.in/dha5d-UZ.
Good packages:
- mockito
- image_picker
- intl
- json_serializable
- freezed
- cached_network_image
By the way, I have my own template, that I recommend taking look as well https://lnkd.in/dz9FR5BG (it's free)