Skip to content

Releases: Frasan00/envitron

v2.3.0

Choose a tag to compare

@Frasan00 Frasan00 released this 31 May 11:28

Environment Manager v2.3.0

🚀 Changelog

Type System Improvements

  • Added EnvironmentCustom type for custom validator support
  • Enhanced InferType utility to handle custom validators
  • Improved type inference for environment variables
  • Fixed enum type definition for readonly arrays

Environment Variable Handling

  • Added custom() validator for user-defined environment-variable validation
  • Improved handling of optional environment variables
  • Enhanced validation logic for required fields
  • Better error handling for undefined values

Schema Validation

  • Added support for custom validation functions
  • Improved type checking for enum values
  • Enhanced validation logic for missing environment variables
  • Fixed type casting issues in Environment Manager

🐛 Bug Fixes

  • Fixed validation logic to properly handle missing environment variables
  • Fixed type casting issues in the Environment Manager
  • Fixed enum type definition to properly handle readonly arrays
  • Improved error handling for undefined values

🧪 Testing

  • Added new test cases for custom validators
  • Enhanced test coverage for optional fields
  • Added tests for edge cases in environment-variable handling

v2.2.0

Choose a tag to compare

@Frasan00 Frasan00 released this 31 May 08:18

Environment Manager v2.2.0

Changelog

Type System Improvements

  • Added AugmentedEnvironmentManager type for better type inference
  • Improved type imports using type keyword for better tree-shaking
  • Enhanced type safety in environment variable access

Environment Variable Handling

  • Fixed loadFromProcessEnv behavior to properly override environment file variables
  • Improved environment file not found handling with better logging
  • Added support for embedded environment variables with direct property access

🐛 Bug Fixes

  • Fixed issue where loadFromProcessEnv wasn't properly overriding environment file variables
  • Fixed environment file not found error handling to be more graceful
  • Fixed type inference issues in the environment manager instance

v2.0.2

Choose a tag to compare

@Frasan00 Frasan00 released this 31 May 07:12

Changelog

FIx:

  1. string not inferred correctly in the get method

Feature:

  1. Added husky pre commit

v2.0.1

Choose a tag to compare

@Frasan00 Frasan00 released this 30 May 23:41

Changelog

removed vitest file from npm package

v2.0.0

Choose a tag to compare

@Frasan00 Frasan00 released this 30 May 23:38

Changelog

Features:

  1. Removed zod dependency in favor of a built in validator
  2. Documentation

v1.8.0

Choose a tag to compare

@Frasan00 Frasan00 released this 01 Feb 10:05

Full Changelog

Feature:

  • set function to set envs at runtime
  • descriptions for lib types
  • typing on env get function

v.1.7.2

Choose a tag to compare

@Frasan00 Frasan00 released this 30 Jan 11:09

Full Changelog

Refactor:

  • Changed getAll() -> all()
  • Unified createEnvSchema and getInstance in order to have an overload handling the difference
  • EnvNames -> string to have more flexibility

v1.7.1

Choose a tag to compare

@Frasan00 Frasan00 released this 05 Jan 15:46

Full Changelog

Removed logfile from winston

v1.7.0

Choose a tag to compare

@Frasan00 Frasan00 released this 31 Dec 17:04

Full Changelog

  • Changed schema to private field
  • Adjusted envs in README example
  • fixed logs property, now it logs only on validation error with logs: true

v1.6.9

Choose a tag to compare

@Frasan00 Frasan00 released this 21 Dec 22:35

Changelog

Removed .env.example from npm package