How can I access response data of api call in react js while request is completing?

Actually I am getting pdf bytes from api call and I want to show pdf data as content is being downloaded but I am not able to access response data before the request is completed and for large pdf files I have to wait for few seconds for request to get completed and display it.