DEV Community

Discussion on: Why Axios is reducing api response?

Collapse
 
itsjzt profile image
Saurabh Sharma
  1. Are you sure axios is causing this? Did you tried fetch?
  2. Maybe Json.parse is causing it
Collapse
 
hasan101002 profile image
Nazmul Hasan👻

i am quite sure that axios is causing this, cause i didn't use any seperate parser . And i can see the original data in network request. But when axios process the response in response.data , it gets reduced . And i didn't try fetch .

Collapse
 
myogeshchavan97 profile image
Yogesh Chavan

It will be better If you could share the code which takes the data from API using Axios so it's easy to understand what is happening.

Thread Thread
 
hasan101002 profile image
Nazmul Hasan👻

updated the post

Thread Thread
 
myogeshchavan97 profile image
Yogesh Chavan

The code looks good to me. I don't see anything wrong here. something is wrong in the backend only from where you're taking the response.

Collapse
 
damiensavoldelli profile image
damienSavoldelli

Could you share an example of data in your network request & what you have in console ?