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

打包后打开html后页面空白并报错 #32

Open
dengzhigang opened this issue Dec 22, 2024 · 2 comments
Open

打包后打开html后页面空白并报错 #32

dengzhigang opened this issue Dec 22, 2024 · 2 comments

Comments

@dengzhigang
Copy link

dengzhigang commented Dec 22, 2024

123

本地运行正常,打包后直接打开就是空白的,并报上图错误,修改vite.config文件中的base配置为''也不行,是不是只能在服务端运行?

@wqzai
Copy link

wqzai commented Dec 22, 2024

进入dist目录使用npm或pnpm run preview,使用http-server也可以

@dengzhigang
Copy link
Author

进入dist目录使用npm或pnpm run preview,使用http-server也可以

非常感谢,已解决。

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