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

message.error/success/... duration argument is optional #7857

Closed
monkindey opened this issue Oct 11, 2017 · 8 comments
Closed

message.error/success/... duration argument is optional #7857

monkindey opened this issue Oct 11, 2017 · 8 comments
Labels

Comments

@monkindey
Copy link
Contributor

@monkindey monkindey commented Oct 11, 2017

What problem does this feature solve?

Because duration have the default value.

message.error(content, duration, onClose)

Sometime I want to use onClose, but have to reassign value to duration even equal to the default value.

What does the proposed API look like?

I can use it two way.

message.error(content, duration, onClose)
message.error(content, onClose)

duration is optional, we can identify the onClose using the typeof

@benjycui
Copy link
Contributor

@benjycui benjycui commented Oct 11, 2017

Just PR to branch antd-3.0, thanks!

@monkindey
Copy link
Contributor Author

@monkindey monkindey commented Oct 12, 2017

Hi, @benjycui . Do you use prettier to format ts code in antd project ?

@monkindey
Copy link
Contributor Author

@monkindey monkindey commented Oct 12, 2017

I run the npm run lint and no warning or error happen, Is what it mean my code follow your eslint?

image

@afc163
Copy link
Member

@afc163 afc163 commented Oct 12, 2017

@monkindey
Copy link
Contributor Author

@monkindey monkindey commented Oct 12, 2017

OK, Thanks. Is there still other step to check before send a PR?

@monkindey
Copy link
Contributor Author

@monkindey monkindey commented Oct 12, 2017

yarn test test is all right

image

@monkindey
Copy link
Contributor Author

@monkindey monkindey commented Oct 12, 2017

I created a feature PR.

@monkindey
Copy link
Contributor Author

@monkindey monkindey commented Oct 14, 2017

I am going to close it because of the #7874

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
3 participants