Files
supabase/apps/docs/content/guides/getting-started
supabase-vercel-tedd[bot]andAlexis Aguilar 78870669cd docs: say where to create the env file in the Vite quickstarts (#53768)
## Problem

The React, Vue, SolidJS and Refine quickstarts tell the reader to create
an env file but not where. The next step creates `src/lib`, so a reader
can put the file in `src/`. Vite loads env files only from the project
root by default, so `import.meta.env.VITE_SUPABASE_URL` then comes back
`undefined`.

Related to
[FDBKIN-25261](https://linear.app/supabase/issue/FDBKIN-25261/clarify-env-file-placement-in-the-react-quickstart-guide)
Closes
[DOCS-1726](https://linear.app/supabase/issue/DOCS-1726/say-where-to-create-the-env-file-in-the-vite-based-quickstarts)

## Solution

The env step of each of these four quickstarts now says to create the
file in the root of the project, next to `package.json`. It reuses the
"in the root of your project" wording that the TanStack and Expo
quickstarts already use, and `package.json` gives the reader a concrete
landmark that rules out `src/`. Only that one sentence changes on each
page.

## How to verify

On the docs preview:

1. `/docs/guides/getting-started/quickstarts/reactjs`, step 6: the first
sentence says to create `.env.local` in the root of your project, next
to `package.json`.
2. `/docs/guides/getting-started/quickstarts/vue`, step 6: same for
`.env.local`.
3. `/docs/guides/getting-started/quickstarts/solidjs`, step 6: same for
`.env.local`.
4. `/docs/guides/getting-started/quickstarts/refine`, step 5: same for
`.env`.
5. No other text on these pages changes.

## Checks

Ran `pnpm turbo run typecheck --filter='...[origin/master]'`, `pnpm
turbo run lint --filter='[origin/master]'` (0 errors), and Prettier on
the four changed files; all pass. Checked against Vite's `envDir` option
(defaults to the project root) and confirmed each page scaffolds a Vite
app. Skipped the docs unit tests: they need Docker.

## Second reader

Verdict: ready, no blockers. One nit: "project" could be read as the
Supabase project, since the same sentence mentions the project Connect
panel. Kept the wording, because "next to `package.json`" settles it and
it matches the sibling quickstarts. Pre-existing issues it noted outside
this change: "populate with" missing "it" on the Vue and SolidJS pages,
missing end punctuation on the React sentence, and the same missing
location in several framework tutorials and the Astro and Nuxt
quickstarts.

## Checklist

- [x] I have read
[CONTRIBUTING.md](https://github.com/supabase/supabase/blob/master/CONTRIBUTING.md)
- [x] If I wrote a new docs topic or edited an existing topic, I used
the `/write-the-docs` or `/edit-the-docs` skill, which applies the docs
[style
guide](https://github.com/supabase/supabase/tree/master/apps/docs/style-guide)

Co-authored-by: supabase-vercel-tedd[bot] <336548405+supabase-vercel-tedd[bot]@users.noreply.github.com>
Co-authored-by: Alexis Aguilar <98043211+alexisintech@users.noreply.github.com>
2026-11-23 13:53:35 -07:00
..