flutter_app_environment 2.0.0
flutter_app_environment: ^2.0.0 copied to clipboard
Simple solution to manage environment variables using `.json` or `.env` files.
2.0.0 #
- Breaking Change: Unified environment initialization into a single
Environment.initmethod. This method is now generic and replaces all previous initialization methods (init,initFromJson, etc.). - Breaking Change: Removed
toShortString()extension method in favor of native.nameproperty. - Improvement: Added support for
.envfiles for environment initialization. - Improvement: Added
EnvironmentSourceTypeto specify the source file format (jsonorenv). - Improvement: Renamed
fromJsonparameter toparserinEnvironment.initto support different source formats. - Improvement: Added basic type inference for
.envvalues (int, double, bool). - Added comprehensive unit tests for
.envparsing andEnvironmentsingleton. - Exported environment exceptions for better error handling by users.
- Renamed internal variable
configMaptocontentMapand addedEnvironment.reset()for testing. - Improvement: Added proper error handling to the initialization process. Now throws
EnvironmentFailedToLoadExceptionon failure.
1.0.4 #
- added new exceptions to improve error handling:
- EnvironmentFailedToLoadException
- EnvironmentAlreadyInitializedException
- EnvironmentNotInitializedException
- improved error handling during environment initialization
1.0.3 #
- refactor documentation and update linting rules for improved code consistency
1.0.2 #
- update docs
- add method initWithCustomType - for use custom environment type from entrypoint
- add method initFromJsonWithCustomType - for use custom environment type from json
1.0.1 #
- environment variables initialization refactor
1.0.0 #
- initial release