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

[BUG] image api 与 mockjs 不兼容 #71

Open
wll8 opened this issue Jan 22, 2021 · 0 comments
Open

[BUG] image api 与 mockjs 不兼容 #71

wll8 opened this issue Jan 22, 2021 · 0 comments
Labels
bug Something isn't working

Comments

@wll8
Copy link
Contributor

wll8 commented Jan 22, 2021

PS: 我叕来提 issue 了~

问题简述
根据 better-mock 的 readme.md 上描述:

100% 兼容 Mock.js。

但是根据 mockjs 的使用文档以及运行结果看来, 与 better-mock 是不相同的.

参考:

复现步骤

Mock.mock(`@image(200x100, #ff0000)`)
// => "https://iph.href.lu/200x100?bg=&fg=&text=#ff0000"
Mock.mock(`@image(200x100, #ff0000)`)
// => "http://dummyimage.com/200x100/ff0000"

期望结果
api 与 mockjs 保持一致.

Mock.mock(`@image(200x100, #ff0000)`)
// => "https://iph.href.lu/200x100?bg=ff0000"
// 或
// => "http://dummyimage.com/200x100/ff0000"
@wll8 wll8 added the bug Something isn't working label Jan 22, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant