你们官网原话是:你可以直接返回数据,也可以通过函数处理以及重定向到另一个服务器。
但是我没看到具体的例子。默认生成的工程中都是使用mock的,我现在希望我自己新加的请求,能直接访问我的后台服务,该怎么配置呢?
Translation of this issue:
The official words of your official website are: you can return data directly, or you can process it through functions and redirect to another server.
But I didn't see a concrete example. The default generated project is to use the mock, I now want my new request, can directly access my background service, how to configure it?
@chenshuai2144 非常感谢,搞定了!
Most helpful comment
https://umijs.org/guide/mock-data.html#mock-data
https://umijs.org/zh/config/#proxy