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

使用/index.html?v=123的方式访问页面时,无法找到页面。 #1524

Closed
hsuna opened this issue Jan 14, 2021 · 0 comments · Fixed by #1526
Closed

使用/index.html?v=123的方式访问页面时,无法找到页面。 #1524

hsuna opened this issue Jan 14, 2021 · 0 comments · Fixed by #1526

Comments

@hsuna
Copy link

hsuna commented Jan 14, 2021

Describe the bug

由于我的项目是使用了多页面,所以需要使用/xxx.html的方式访问页面,但是开发过程中发现,如果使用xxx.html访问是可以的,但是一旦带了参数就无法找到页面的,例如:/xxx.html?id=aaa

Reproduction

可以直接使用 yarn create @vitejs/app 生成的 vue 模板尝试,运行后尝试以下方式访问就可以复现:

访问路径 能否访问
http://localhost:3000/
http://localhost:3000/?v=123
http://localhost:3000/index.html
http://localhost:3000/index.html?v=123 ×

System Info

  • vite version: 2.0.0-beta.27
  • Operating System: Window
  • Node version: 12.19.0
  • Package manager (npm/yarn/pnpm) and version: yarn 1.22.10
underfin added a commit to rolldown/vite that referenced this issue Jan 14, 2021
underfin added a commit to rolldown/vite that referenced this issue Jan 14, 2021
@github-actions github-actions bot locked and limited conversation to collaborators Jul 16, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants