Skip to content

请教关于设置代理解决跨域的问题 #59

@RBqingkong

Description

@RBqingkong

系统环境为MAC
直接用 ykit s -p 4000 启动服务器,然后前端请求接口也是127.0.0.1:4000;
请教下怎么设置代理呢,我试过在ykit.config的 server 中加上 proxy: { '/api': { target: 'http://127.0.0.1:3000', changeOrigin: true } }
但是没有生效

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions