We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Hello Team,
Looks like response.clone() does not work as expected when trying to re-read the response.
response.clone()
const myRequest = new Request('https://restcountries.com/v3.1/region/europe'); fetch(myRequest) .then((response) => { const response2 = response.clone(); response.json().then((myRes) => { console.log('Response', myRes); }); response2 .json() .then((myRes) => { console.log('Response2 --->', myRes); }) .catch((e) => { console.log('@@@@@@'); console.log(e); console.log('@@@@@@'); }); });
@@@@@@ [TypeError: This stream has already been locked for exclusive reading by another reader] @@@@@@```
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Hello Team,
Looks like
response.clone()
does not work as expected when trying to re-read the response.The text was updated successfully, but these errors were encountered: