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

[IRouter] 编译之后的静态资源放在后端项目中一起发布,需要路由问题 #2419

Closed
legend91325 opened this issue Aug 4, 2023 · 2 comments

Comments

@legend91325
Copy link

重现链接

https://github.com/Tencent/tdesign-react

重现步骤

讲编译好的静态文件统一放在后端项目的一个ui文件夹中,直接访问 http://xxxx/ui/index.html 页面,可以正常访问,点击页面也可以正常操作,但是刷新浏览器,直接访问路由地址,因为是通过后端项目访问,无法定位页面 ,报错404

期望结果

如何配置IRouter ,和后端转发地址 才能做到刷新浏览器 访问依旧可以正确访问页面

实际结果

刷新浏览器,直接访问路由地址,因为是通过后端项目访问,无法定位页面 ,报错404

Environment Info
相关版本 1.1.17
框架版本 / 基础库版本 React(1.1.17)
系统、浏览器 Chrome
Node版本 v18.16.1
@github-actions
Copy link
Contributor

github-actions bot commented Aug 4, 2023

👋 @legend91325,感谢给 TDesign 提出了 issue。
请根据 issue 模版确保背景信息的完善,我们将调查并尽快回复你。

@uyarn
Copy link
Collaborator

uyarn commented Aug 9, 2023

这个与组件无关 可以参考下react-starter或者其他admin项目的代码

@uyarn uyarn closed this as completed Aug 9, 2023
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

No branches or pull requests

2 participants