# Frontend Delivery Env Management

> Standardized guidelines and patterns for Frontend Delivery Env Management.

- Skill: `valec3/frontend-delivery-env-management` (Agent Skill)
- Install (CLI): `npx skillmds add valec3/frontend-delivery-env-management`
- Raw SKILL.md: https://api.skillmd.com/api/skills/valec3/frontend-delivery-env-management/raw
- Safety review: pending
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: Web & Frontend
- Author: valec3 (https://skillmd.com/u/valec3)
- Updated: 2026-09-10
- Page: https://skillmd.com/skills/valec3/frontend-delivery-env-management

---


# Frontend Delivery Env Management

## When to use this skill
- Managing environment variables
- Configuring for different environments
- Handling secrets

## Workflow
- [ ] Create .env files
- [ ] Use environment-specific configs
- [ ] Never commit secrets
- [ ] Validate env vars at startup
- [ ] Document required vars

## Instructions

### .env Files
```bash
# .env.local (not committed)
VITE_API_URL=http://localhost:3000

# .env.production
VITE_API_URL=https://api.example.com
```

### Usage
```typescript
const apiUrl = import.meta.env.VITE_API_URL;
```

### Validation
```typescript
const requiredEnvVars = ['VITE_API_URL'];
requiredEnvVars.forEach(key => {
  if (!import.meta.env[key]) {
    throw new Error(`Missing env var: ${key}`);
  }
});
```

## Resources
- Prefix with VITE_ or NEXT_PUBLIC_
- Never commit secrets
- Validate at startup

