docs: document admin environment variables (#11313)
This commit is contained in:
@@ -94,3 +94,11 @@ In the `medusa-config.ts` file of your Medusa application, you'll find a `loadEn
|
||||
This function is responsible for loading the correct `.env` file based on the value of `process.env.NODE_ENV`.
|
||||
|
||||
To ensure that the correct `.env` file is loaded as shown in the table above, only specify `development`, `production`, `staging` or `test` as the value of `process.env.NODE_ENV` or as the parameter of `loadEnv`.
|
||||
|
||||
---
|
||||
|
||||
## Environment Variables for Admin Customizations
|
||||
|
||||
Since the Medusa Admin is built on top of [Vite](https://vite.dev/), you prefix the environment variables you want to use in a widget or UI route with `VITE_`. Then, you can access or use them with the `import.meta.env` object.
|
||||
|
||||
Learn more in [this documentation](../admin/environment-variables/page.mdx).
|
||||
|
||||
Reference in New Issue
Block a user