nginx中配置react-router参数跳转
生活随笔
收集整理的这篇文章主要介绍了
nginx中配置react-router参数跳转
小编觉得挺不错的,现在分享给大家,帮大家做个参考.
2019独角兽企业重金招聘Python工程师标准>>>
location / {root /home/iwork;index index.html;try_files $uri /index.html; #这句关键哦 }#子路径刷新 location ^~ /main {try_files $uri /index.html; }#代理 location ^~ /iwork/ {proxy_pass http://192.168.0.193:8080/iwork/;proxy_set_header Host $host;proxy_set_header X-Real-IP $remote_addr;proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; }nginx 只匹配 / ,剩下的应该由react-router来做
转载于:https://my.oschina.net/xuqiang/blog/690705
总结
以上是生活随笔为你收集整理的nginx中配置react-router参数跳转的全部内容,希望文章能够帮你解决所遇到的问题。
- 上一篇: static在类中的定义,和enum的用
- 下一篇: PowerShell 收集计算机相关信