-
Notifications
You must be signed in to change notification settings - Fork 85
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
remove ajaxPost / ajaxGet generic arguments when redundant
- Loading branch information
1 parent
c4b8275
commit 99ea65e
Showing
3 changed files
with
28 additions
and
28 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
99ea65e
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove ajaxGet / ajaxPost generic parameter
Looks like Typescript is able to infer the generic parameter from the target type.
![image](https://user-images.githubusercontent.com/720953/67552862-2db4c280-f70c-11e9-8092-08213bcf75b3.png)
So we can remove some duplication in all the API modules.
This is the regex that you can run in your own React project: