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: add base to virtual html #16442

Merged
merged 2 commits into from
Apr 18, 2024

Conversation

XiSenao
Copy link
Collaborator

@XiSenao XiSenao commented Apr 17, 2024

Copy link

stackblitz bot commented Apr 17, 2024

Review PR in StackBlitz Codeflow Run & review this pull request in StackBlitz Codeflow.

@XiSenao XiSenao added the p3-minor-bug An edge case that only affects very specific usage (priority) label Apr 17, 2024
sapphi-red
sapphi-red previously approved these changes Apr 17, 2024
@sapphi-red
Copy link
Member

/ecosystem-ci run

@@ -200,7 +200,7 @@ const devHtmlHook: IndexHtmlTransformHook = async (
// and ids are properly handled
const validPath = `${htmlPath}${trailingSlash ? 'index.html' : ''}`
proxyModulePath = `\0${validPath}`
proxyModuleUrl = wrapId(proxyModulePath)
proxyModuleUrl = joinUrlSegments(base, wrapId(proxyModulePath))
Copy link
Member

Choose a reason for hiding this comment

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

Maybe we could move the joinUrlSegments out of these two branches so it is more clear that this always need to be added.

proxyModuleUrl = joinUrlSegments(base, proxyModuleUrl)

@patak-dev patak-dev merged commit 721f94d into vitejs:main Apr 18, 2024
10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
p3-minor-bug An edge case that only affects very specific usage (priority)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Dev server fails to load the scripts with 404 when using Vite base option and virtual modules
3 participants