Typenv is a Visual Studio Code extension that enhances your experience when working with custom .envx environment schema files.
It offers schema validation, key suggestions, real-time diagnostics, and hover documentation to help you write reliable environment configurations.
✨ Features
Environment key autocomplete
When typing > in the assignment section, all defined schema keys (e.g., API_URL, PORT, DB_NAME) are suggested.
Example:
> API_KEY
This helps prevent typos and speeds up configuration.
Schema-based key/value support
Supports structured schema keys such as type, required, default, description, and values.
Inline diagnostics
Detects and warns about:
Missing or invalid types
Using values without enum type
Required keys without a default or assignment
Deprecated keys that are still in use
Hover tooltips
Displays key descriptions and schema metadata on hover.
Multi-line descriptions
Write descriptive documentation using triple quotes:
description = """This key is used for the main API authentication."""
🛠 Usage
Create or open a .envx file.
Define your schema using sections like:
[API_URL]
type = url
required = true
In your main assignment area, start a new line and type > to see key suggestions:
> API_URL
> PORT
> DB_NAME
These suggestions are populated from the schema section headers (e.g., [PORT], [DB_NAME], etc.).
Assign values to these keys:
envx API_URL=https://api.example.com PORT=3000
Hover over keys to see detailed descriptions, or look for inline errors as you type.
🔍 Example
# Actual assignments
PORT=3000
ENVIRONMENT=staging
[PORT]
type = number
required = true
description = """Port used for the backend server"""
[ENVIRONMENT]
type = enum
values = development, staging, production
default = development
🤝 Contributing
Have ideas or found a bug? Open an issue or PR on GitHub – contributions are welcome!