federation icon indicating copy to clipboard operation
federation copied to clipboard

makeRequest method to modify url and method

Open yawningphantom opened this issue 4 years ago • 2 comments

#901 This PR enables us to modify the url and the http method for every request. The url change was easy but to enable the http method change I had to change the sendRequest method as it is always sending the body in the request and when you do it for a GET request it throws up a type error TypeError: Request with GET/HEAD method cannot have body here hence I had to change the implementation of sendRequest I would recommend that we call the makeRequest method inside the sendRequest itself so that we can create the Request object dynamically and this can be modified.

yawningphantom avatar Aug 15 '21 12:08 yawningphantom

@yawningphantom: Thank you for submitting a pull request! Before we can merge it, you'll need to sign the Apollo Contributor License Agreement here: https://contribute.apollographql.com/

apollo-cla avatar Aug 15 '21 12:08 apollo-cla

@trevor-scheer any update on this PR?

yawningphantom avatar Nov 08 '21 07:11 yawningphantom