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

Return current window location href as API url #40

Merged
merged 2 commits into from
Mar 5, 2024

Conversation

eengnr
Copy link
Contributor

@eengnr eengnr commented Feb 27, 2024

With this change, the API URL which is used by the frontend is always the same like the URL for the frontend itself.
Only if the frontend is loaded from localhost / 127.0.0.1, i.e. during local development of the frontend, the API call is sent towards winderoo.local, i.e. to the backend running on the ESP32.

This is a workaround for the mDNS issue on Android in #39 and should hopefully not break anything else. With this it's possible to load the frontend from the ESP32 IP instead of the winderoo.local domain provided by mDNS.

@mwood77
Copy link
Owner

mwood77 commented Feb 27, 2024

Great! Can you please include a new build of the FE too? That way, it'll be available in main, and all people need to do is build & upload the filesystem to their esp32.

All you need to do is run npm run build-arduino and check-in the result of that into this PR.

Copy link
Owner

@mwood77 mwood77 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanks again!

@mwood77 mwood77 merged commit 7177daa into mwood77:main Mar 5, 2024
4 checks passed
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.

None yet

2 participants