This tool works with both Expo and React Native CLI projects. Just install and go.
The Environment Inspector tool lets you view and validate environment variables in your React Native app. It automatically discovers EXPO_PUBLIC_ prefixed variables and provides validation, type detection, and health monitoring.
Don't take our word for it — this is the real tool, running right here on a mock build. The guided tour below walks one debugging story: vars stream in as discovered, a declared contract lights up what never shipped, you read exactly what's wrong, compare two builds' health, and land the fix. Or skip the tour and just start tapping:
Not a video — this is the shipped tool on a mock build. Every EXPO_PUBLIC_ var the binary actually resolved streams in: auto-discovered, auto-typed, zero config.
npm install @buoy-gg/envAfter installation, the Environment Inspector will be auto-detected and appear in your FloatingDevTools menu.
For more control, use createEnvTool with the envVar builder to define required variables and validation rules:
import { createEnvTool, envVar } from "@buoy-gg/env";
const envTool = createEnvTool({
requiredEnvVars: [
envVar("EXPO_PUBLIC_API_URL").exists(),
envVar("EXPO_PUBLIC_DEBUG_MODE").withType("boolean").build(),
envVar("EXPO_PUBLIC_ENVIRONMENT").withValue("development").build(),
envVar("EXPO_PUBLIC_MAX_RETRIES")
.withType("number")
.withDescription("Maximum API retry attempts")
.build(),
],
});
import { createEnvTool, envVar } from "@buoy-gg/env";
const envTool = createEnvTool({
requiredEnvVars: [
envVar("EXPO_PUBLIC_API_URL").exists(),
envVar("EXPO_PUBLIC_DEBUG_MODE").withType("boolean").build(),
envVar("EXPO_PUBLIC_ENVIRONMENT").withValue("development").build(),
envVar("EXPO_PUBLIC_MAX_RETRIES")
.withType("number")
.withDescription("Maximum API retry attempts")
.build(),
],
});
The fluent builder API makes it easy to define environment variable requirements:
envVar("API_KEY")
.withType("string") // Set expected type
.withValue("sk_test_123") // Or set expected value
.withDescription("API Key") // Add documentation
.build() // Finalize config
// Shorthand for just checking existence
envVar("API_KEY").exists()
envVar("API_KEY")
.withType("string") // Set expected type
.withValue("sk_test_123") // Or set expected value
.withDescription("API Key") // Add documentation
.build() // Finalize config
// Shorthand for just checking existence
envVar("API_KEY").exists()
type EnvVarType = "string" | "number" | "boolean" | "array" | "object" | "url";
type EnvVarType = "string" | "number" | "boolean" | "array" | "object" | "url";
createEnvTool({
name?: string; // default: "ENV"
description?: string;
colorPreset?: "orange" | "cyan" | "purple" | "pink" | "yellow" | "green"; // default: "green"
id?: string; // default: "env"
requiredEnvVars?: RequiredEnvVar[];
enableSharedModalDimensions?: boolean;
});
createEnvTool({
name?: string; // default: "ENV"
description?: string;
colorPreset?: "orange" | "cyan" | "purple" | "pink" | "yellow" | "green"; // default: "green"
id?: string; // default: "env"
requiredEnvVars?: RequiredEnvVar[];
enableSharedModalDimensions?: boolean;
});
| Status | Description |
|---|---|
| required_present | Required var is set and correct |
| required_missing | Required var is not set |
| required_wrong_value | Set but doesn't match expected value |
| required_wrong_type | Set but wrong type |
| optional_present | Optional var that is set |
Use the interactive builder below to create your environment validation config. Add variables, configure checks (type, value, description), and export the code directly.
import { envVar, createEnvTool } from "@buoy-gg/env";
const envTool = createEnvTool({
requiredEnvVars: [
envVar("API_URL").withType("url").build(),
envVar("AUTH_TOKEN").exists(),
envVar("DEBUG").withType("boolean").build(),
envVar("SECRET_KEY").withValue("sk_*").build(),
envVar("ENVIRONMENT").withValue("production or development").build(),
],
});import { envVar, createEnvTool } from "@buoy-gg/env";
const envTool = createEnvTool({
requiredEnvVars: [
envVar("API_URL").withType("url").build(),
envVar("AUTH_TOKEN").exists(),
envVar("DEBUG").withType("boolean").build(),
envVar("SECRET_KEY").withValue("sk_*").build(),
envVar("ENVIRONMENT").withValue("production or development").build(),
],
});Install @buoy-gg/env and open the Env tool — it auto-discovers EXPO_PUBLIC_ variables and shows the value each one resolved to in the running build.
Yes — attach expected types and custom validators, and failures show the current value, expected value, and context.