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

fix: to make config hmr work in windows #364

Merged
merged 2 commits into from
Oct 7, 2021
Merged

Conversation

CHOYSEN
Copy link
Contributor

@CHOYSEN CHOYSEN commented Aug 14, 2021

fix #372

@CHOYSEN CHOYSEN closed this Aug 14, 2021
@CHOYSEN CHOYSEN deleted the fix/02 branch August 14, 2021 09:09
@CHOYSEN CHOYSEN restored the fix/02 branch August 14, 2021 09:10
@CHOYSEN CHOYSEN reopened this Aug 14, 2021
@CHOYSEN CHOYSEN changed the title fix: to make config hmr work in window fix: to make config hmr work in windows Aug 14, 2021
@posva posva added the need more info Further information is requested label Aug 15, 2021
@posva
Copy link
Member

posva commented Aug 15, 2021

Do tou have a repro?

@CHOYSEN
Copy link
Contributor Author

CHOYSEN commented Aug 15, 2021

Just use Vitepress in Windows that can repro it.

The following line will resolve configPath that use backslash in Windows:c:\test-vitepress\docs\.vitepress\config.js

configPath: resolve(root, 'config.js'),

The file is normalized by Vite:c:/test-vitepress/docs/.vitepress/config.js, so they never equal in Windows.

if (file === configPath) {

@yyx990803 yyx990803 merged commit 58663bb into vuejs:main Oct 7, 2021
@CHOYSEN CHOYSEN deleted the fix/02 branch October 8, 2021 07:17
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jan 21, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
need more info Further information is requested
Projects
None yet
Development

Successfully merging this pull request may close these issues.

hmr does not take effect for config.js
3 participants