Skip to content

webpack 配置代理后路由跳转有问题 #13

@lin-mt

Description

@lin-mt

Basic Info

  • Package Name And Version: "@arco-design/webpack-plugin": "^1.5.2"
  • System: mac os
  • Browser: chrome
  • Reproduction Link: 官方是否可以提供一个简易的 jsfiddle/codepen/codesandbox 例子,我们再根据这个例子 fork 出来重现 bug,这样会方便一点~

What is expected?

登陆成功后,正常跳转

Steps to reproduce

如果有登陆,先退出登陆

  1. 在 webpack.config.js 添加配置
  config.devServer = {
    proxy: {
      '/simpleProxy': {
        target: 'http://localhost:8080',
        changeOrigin: true,
        pathRewrite: { '^/simpleProxy': '' },
      },
    }
  }
  1. 输入账号密码,点击登陆

image

  1. 浏览器重新访问 http://localhost:9090/ 后,才可以正常访问

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions