WongSaang/chatgpt-ui

yarn dev 启动前端,代理不生效

Closed this issue · 1 comments

nuxt.config.ts里面配置了

    nitro: {
        devProxy: {
            "/api": {
                target: 'http://localhost:8000/api',
                prependPath: true,
                changeOrigin: true,
            }

        }
    },

另外http://localhost:8000/api可以正常请求

但是通过前端api http://localhost:3000/api/account/registration/ 直接报错500,后端服务也没有请求日志

请问是哪里的问题呢?
image

不好意思,是localhost的问题,改为IP可以了