Last active
July 21, 2020 06:30
-
-
Save jpulec/eced963537b221650793f56140b57f2e to your computer and use it in GitHub Desktop.
Request Wrapper
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
import request from 'request'; | |
const myRequests = { | |
get: (...args) => request.get(...args), | |
post: (...args) => request.post(...args), | |
patch: (...args) => request.patch(...args), | |
delete: (...args) => request.delete(...args), | |
put: (...args) => request.put(...args), | |
}; | |
export default myRequests; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment