Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add dynamic build vars for web's index.html #183

Merged
merged 1 commit into from
Aug 16, 2024
Merged

Conversation

benjreinhart
Copy link
Contributor

Locally we run dev server and API on separate hosts. In prod, these are the same and also should be computed at runtime (window.location.*) to account for localhost aliases.

See https://vitejs.dev/guide/env-and-mode#html-env-replacement

(they can also be overridden with an env file with a .local suffix).

@benjreinhart benjreinhart requested a review from nichochar August 16, 2024 00:10
@benjreinhart benjreinhart merged commit 4b24bdf into main Aug 16, 2024
1 check passed
@benjreinhart benjreinhart deleted the dynamic-build-vars branch August 16, 2024 00:14
@nichochar
Copy link
Contributor

LGTM

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants