-
Notifications
You must be signed in to change notification settings - Fork 80
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
【小白 请教接口 ts使用】 #46
Comments
谢谢大佬, 我想再请问一哈, dataKey在这种情况就不能完全满足。 目前我们的解决方案是根据yapi-to-typescript 自动生成 然后copy 出去组装对应业务代码。 |
dataKey 可以在服务器级别、项目级别、分类级别配置,只要保证某个分类下的返回结果一样,就行了 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
大佬, 请教一哈, 从yai拉去返回的接口是完整的。 比如说 { result: { code: 0, status: 'success' }, data: [{ title: '业务数据' }]}
这个时候通过泛型 请求接口axios 是能获取到提示类型的。
想请问一哈, 业务使用的时候, 只需要业务数据定义的ts interface, 需要剔除返回状态吗, 实现共用。
不知道大佬是怎么在项目中实现的此类业务场景的
The text was updated successfully, but these errors were encountered: