/expo-stack:setup [--convex cloud|self-hosted] [--skip-build]from expo-stack
Completes first-run setup for a scaffolded expo-stack app — configures Convex (cloud or self-hosted), sets environment variables and secrets, verifies the backend, and prepares a dev build.
Ships in expo-stack. Installing the plugin adds it to Claude Code.
Take a freshly scaffolded app from "files on disk" to "running on a device, signed in, showing real data". Run once, right after /expo-stack:new.
The scaffold deliberately stops before anything that needs credentials or a network account. This is that part.
Each step's output feeds the next, so do not parallelise them.
Read package.json and app.json. If there is no convex/ directory or no src/app/_layout.tsx, this is not an expo-stack app — say so and offer /expo-stack:new instead.
Check whether .env.local already exists. If it does, this app is probably already set up: run /expo-stack:doctor instead and only fix what it reports. Do not overwrite a working .env.local.
Cloud:
npx convex dev # interactive: creates or selects a deployment
It writes CONVEX_DEPLOYMENT and generates convex/_generated/. Let it finish and leave it running in the background — codegen is what makes tsc pass.
Self-hosted:
docker compose -f self-hosted/docker-compose.yml up -d
docker compose -f self-hosted/docker-compose.yml exec backend ./generate_admin_key.sh
Then set CONVEX_SELF_HOSTED_URL and CONVEX_SELF_HOSTED_ADMIN_KEY in .env.local and run npx convex dev. self-hosted/SELF-HOSTING.md has the details.
Copy .env.example to .env.local and fill in:
| Cloud | Self-hosted | |
|---|---|---|
EXPO_PUBLIC_CONVEX_URL | https://<name>.convex.cloud | port 3210 |
EXPO_PUBLIC_CONVEX_SITE_URL | https://<name>.convex.site | port 3211 |
Read them back to the user before moving on. These are different endpoints, and swapping them produces a failure that points at neither: queries work but sign-in 404s, or auth works and no data arrives. Thirty seconds here saves an afternoon.
Never set both the cloud and self-hosted variable sets — Convex refuses to start with a mix, on purpose.
npx convex env set BETTER_AUTH_SECRET="$(openssl rand -base64 32)"
Convex env, never .env. Only EXPO_PUBLIC_* reaches the client bundle, so a secret placed there ships to every user's device.
If the user wants social sign-in, their provider client IDs and secrets go the same way, and the redirect URI is <site-origin>/api/auth/callback/<provider>.
curl -s -o /dev/null -w '%{http_code}\n' "$EXPO_PUBLIC_CONVEX_SITE_URL/api/auth/session"
Anything other than a 2xx/4xx answer — a connection error or a 404 — means convex/http.ts was never pushed, or the site origin is wrong. Fix it here. Debugging this from inside the app is much harder.
Most of this stack is native — RevenueCat, react-native-ease, TrueSheet, Skia, keyboard-controller — so Expo Go cannot run it. Recent SDKs cannot run in App Store Expo Go at all.
npx expo run:ios # or: eas build --profile development --platform ios
npx expo run:android
Skip with --skip-build if the user already has a dev build installed.
Do not report success from a clean build log. Drive the real app with argent: list-devices → boot-device → launch-app → describe → gesture-tap. Never take tap coordinates from a screenshot.
Walk the path that exercises every layer:
dark: variants applyIf any step fails, fix it before declaring setup done. A green build with a broken sign-in is not set up.
State plainly what is working, what is left, and what needs an account the user has to create (Apple Developer, Google Play, RevenueCat). Then point at the next command:
/expo-stack:rebrand — name, identity, colours/expo-stack:customize-onboarding — the first-run flow/expo-stack:configure-monetization — if it sells anything/expo-stack:add-language — more locales/expo-stack:ship — variants, builds, store submission.env.local.What the command file sets; muted values are Claude Code's defaults
7-day visitors to each command page
npx claudepluginhub flyingwebie/skills --plugin expo-stack10 commands in this plugin
/add/expo-stack:addLayer one part of the expo-stack onto an existing Expo app/add-language/expo-stack:add-languageAdd a language to the app — creates the typed locale file, registers it, and translates the strings/configure-monetization/expo-stack:configure-monetizationWire up RevenueCat — keys, entitlements, paywall placement, gating, and the store-review requirements/customize-onboarding/expo-stack:customize-onboardingDesign or rework the first-run experience — pre-sign-in steps, post-sign-up setup, gating and permissions/doctor/expo-stack:doctorAudit an existing Expo project against the expo-stack rules and install the upstream skill packs/new/expo-stack:newScaffold a production-grade Expo app on the expo-stack (Expo Router + Convex + Better Auth + Uniwind + i18n + onboarding)Other plugins' commands for the same job