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

[1.x] Hot file monitoring #323

Draft
wants to merge 4 commits into
base: 1.x
Choose a base branch
from
Draft

[1.x] Hot file monitoring #323

wants to merge 4 commits into from

Conversation

timacdonald
Copy link
Member

This PR allows 3rd party tools, such as Expose, to control the URL in the hot file. The URL in the hot file is used by both Laravel and Vite when rendering URLs to the Vite server.

When the URL in the hot file is updated, the plugin will use the new URL when rendering URLs in JS and CSS assets. It will also perform a full page reload when the hot file is updated which should be a nice DX, e.g., when Expose starts it can write a new URL to the hot file, handle proxying that URL back to the Vite server, and the page will refresh to start using the new dev server URL all automatically.

An example log, which matches how Vite formats their log messages for similar events:

Screenshot 2025-02-21 at 10 54 46

@timacdonald timacdonald changed the title Hot file monitoring [1.x] Hot file monitoring Feb 20, 2025
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.

1 participant