flutter_env_gen 1.0.0 copy "flutter_env_gen: ^1.0.0" to clipboard
flutter_env_gen: ^1.0.0 copied to clipboard

Type-safe environment configuration generator for Flutter. Generate strongly-typed Dart code from .env files with automatic type detection and compile-time constants.

Changelog #

1.0.0 - 2024-11-11 #

Initial Release #

  • Type-safe code generation from .env files
  • Automatic type detection for String, int, double, bool, and List types
  • Multiple environment support (dev, staging, production)
  • Compile-time constants for better performance
  • Sensitive data obfuscation for keys containing SECRET, KEY, TOKEN, PASSWORD
  • Customizable field naming with snake_case to camelCase conversion
  • Required keys validation at build time
  • Build_runner integration for seamless code generation
  • Full IDE support with autocomplete and type checking
  • No runtime parsing - all values are compile-time constants
  • Secure by design - .env files are not included in final APK/IPA

Features #

  • Generate strongly-typed Dart classes from environment files
  • Support for String.fromEnvironment, int.fromEnvironment, bool.fromEnvironment
  • List parsing from comma-separated values
  • Custom output path configuration
  • Configurable class name and field renaming
  • Build-time validation of required keys
  • Example project with complete usage demonstration

Documentation #

  • Comprehensive README with usage examples
  • Comparison with flutter_dotenv
  • Migration guide from runtime to compile-time configuration
  • Complete API documentation
1
likes
0
points
42
downloads

Documentation

Documentation

Publisher

unverified uploader

Weekly Downloads

Type-safe environment configuration generator for Flutter. Generate strongly-typed Dart code from .env files with automatic type detection and compile-time constants.

Repository (GitHub)
View/report issues

Topics

#environment #configuration #code-generation #build-runner #env

License

unknown (license)

Dependencies

analyzer, build, code_builder, collection, dart_style, glob, path, source_gen, yaml

More

Packages that depend on flutter_env_gen