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 the delay prop to the server restart #23

Closed
3 tasks done
gTutini opened this issue Jun 25, 2024 · 0 comments
Closed
3 tasks done

Add the delay prop to the server restart #23

gTutini opened this issue Jun 25, 2024 · 0 comments
Labels
enhancement New feature or request

Comments

@gTutini
Copy link
Contributor

gTutini commented Jun 25, 2024

Clear and concise description of the problem

I needed to use the ViteRestart to reboot my server everytime that a local lib, that I have linked with my project, rebuilds.
As I added the delay param, I realized that it actually has no effect on the restart paths, instead working only with the reload ones.
That way, while my lib rebuilds, the project restarts with the old files and the new files does not load with the changes I just made.

Suggested solution

We can just wrap the existing schedule function around the server.restart() at line 91. That way, the server will restart based on the delay param, as the reload function already does.

Alternative

No response

Additional context

No response

Validations

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

No branches or pull requests

1 participant