我创建了我的React App,npm run build
...把我的文件放在filezilla中,但问题是我有这个错误
Not Found
The requested URL /main was not found on this server.
当我去https://clickswinner.alwaysdata.net以外的页面
你有什么建议的?
尝试创建.htaccess文件并将其放在服务器的根目录下
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.html$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . index.html [L]
</IfModule>
谷歌是你的朋友
这是一篇关于如何解决Filezilla https://medium.com/@christine_tran/deploying-a-simple-react-application-using-ftp-filezilla-dreamhost-1e5ff6b8abd6 404问题的文章