Skip to content

Add facade layer for environment variables in @next-pms/app#734

Open
anmol-fzr wants to merge 1 commit intortCamp:mainfrom
anmol-fzr:refactor/envs-layer
Open

Add facade layer for environment variables in @next-pms/app#734
anmol-fzr wants to merge 1 commit intortCamp:mainfrom
anmol-fzr:refactor/envs-layer

Conversation

@anmol-fzr
Copy link
Copy Markdown

This PR introduces a facade layer (envs) for managing environment variables in the Vite application.

Changes:

  • Created a frozen envs object to prevent accidental mutation.
  • Nested objects for related configuration: SOCKET, SITE.
  • Simplifies and standardizes access to environment variables across the app.

Motivation:

  • Improves maintainability and readability.
  • Provides a safe and consistent way to use environment config.
  • Prepares codebase for future scaling and modularization.

- Introduced a frozen `envs` object to safely access Vite environment
variables
- Grouped related envs (DEV, SOCKET, SITE) using nested frozen objects
- Provides a consistent, immutable interface for accessing environment
config
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant