Skip to content
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

mock 方案调研 #55

Closed
MuYunyun opened this issue Oct 7, 2018 · 0 comments
Closed

mock 方案调研 #55

MuYunyun opened this issue Oct 7, 2018 · 0 comments
Labels
practice do some research

Comments

@MuYunyun
Copy link
Owner

MuYunyun commented Oct 7, 2018

当前痛点

  • 前端必须依赖后端接口返回的数据以及格式
  • 后端同学接口文档变更,无法及时响应
  • 本地造数据的成本比较大, 而且 mock 数据污染代码

当下急切寻找一个平台级的 mock 方案,在各个系统间使用无差别利于推广。调研开始。

easy-mock

大搜车推出的 mock 方案。

优势:前端团队间合作较为容易;支持部署到公司内网;支持 swager;
缺点:需掌握 mock.js 的语法,有一定上手成本;还是得依赖后端定好相应的数据格式;

zan-api

有赞前端推出的 mock 方案。目前感觉这个好玩的点比较多,但是并没有开源。

难点:

  • 后端生成 javadoc 的时候如何在平台上生成一份额外的 api;
  • 根据这份参数(以及参数类型)自动生成 mock 数据;
  • 前端调用平台数据的方式;
@MuYunyun MuYunyun added the practice do some research label Oct 7, 2018
@MuYunyun MuYunyun closed this as completed Mar 2, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
practice do some research
Projects
None yet
Development

No branches or pull requests

1 participant