我正在尝试将基于反应的应用程序与同一服务器上的其他位置进行反向代理,当我添加一个包含'#'(反应散列路由)的位置时,它会被忽略,因为该位置被忽略从哈希开始。以下是我的服务器配置
location / {
return 301 /#/target;
}
location /#/target {
proxy_pass http://localhost:8000
}
由于基于散列的路线,它会被忽略并与位置匹配' /'并以无限循环结束
location / {
return 301 /target;
}
location /target {
proxy_pass http://localhost:8000
}
以上作品。有没有办法逃避哈希?我尝试用双引号。