solidstart-environment

Manage SolidStart environment variables with VITE_ prefix and process.env.

Updated Jan 4, 2026
One-click install
npx skills add https://github.com/vallafederico/solid-ai-rules --skill solidstart-environment
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: solidstart-environment
Source: https://github.com/vallafederico/solid-ai-rules/tree/main/.claude/skills/solidstart-environment
Command: npx skills add https://github.com/vallafederico/solid-ai-rules --skill solidstart-environment

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill clarifies how to correctly manage environment variables in SolidStart applications, ensuring sensitive data remains secure and development is type-safe.

Core Features & Use Cases

  • Public vs. Private Variables: Differentiates between VITE_ prefixed variables for client-side use and server-only variables.
  • Type Safety: Guides on using env.d.ts for TypeScript autocompletion and type checking.
  • Environment Files: Explains the hierarchy and usage of .env, .env.local, and mode-specific files.
  • Use Case: Securely configure your SolidStart app by defining API endpoints for the client (VITE_API_URL) and database credentials for the server (DATABASE_URL) using the correct methods.

Quick Start

Configure your SolidStart application's environment variables by defining public variables with the VITE_ prefix and private variables using process.env.

Frequently Asked Questions about solidstart-environment

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I manage environment variables in SolidStart for public and private data?▼

SolidStart environment variable management uses the VITE_ prefix for public client-side variables and process.env for private server-only variables, ensuring sensitive data remains secure while allowing safe client-side access.

What is the difference between VITE_ prefixed variables and process.env in SolidStart?▼

VITE_ prefixed variables expose data to the client-side browser, while process.env restricts variables to the server-only runtime, preventing sensitive data exfiltration by keeping private credentials inaccessible from frontend code.

How do I add TypeScript type safety for SolidStart environment variables?▼

TypeScript type safety for SolidStart environment variables is achieved by defining types in an env.d.ts file, enabling autocompletion and type checking for both VITE_ public variables and process.env server-only variables.

Does SolidStart support different .env file configurations for development and production?▼

SolidStart supports environment file precedence using .env, .env.local, and mode-specific files, allowing distinct configurations for development and production environments based on the active build mode.

Why does my SolidStart environment variable return undefined at runtime?▼

SolidStart environment variables may return undefined at runtime if you mix build-time and runtime variable distinctions, or if a server-only process.env variable is incorrectly accessed on the client-side without the VITE_ prefix.