PHPFixing
  • Privacy Policy
  • TOS
  • Ask Question
  • Contact Us
  • Home
  • PHP
  • Programming
  • SQL Injection
  • Web3.0

Friday, October 14, 2022

[FIXED] What is the difference between Axios and SuperAgent libraries?

 October 14, 2022     axios, javascript, superagent     No comments   

Issue

I am learning JavaScript and I can see, in multiple big projects, SuperAgent is being used for HTTP Request. I am using Axios for learning purpose, but wondering what makes SuperAgent different to Axios?


Solution

axios has more stars than superagent, check here

If you are doing front end, axios is probably more popular, e.g. vue uses axios, I am doing back end, either one works.

But just like one answer in Axios vs Superagent said "I’d base my decision on other factors, like which API you like better, and library size " I tried both and finally chose supergent b/c superagent has build-in retry

axios does not provide retry, https://github.com/axios/axios/issues/164. I really don't like the idea of introducing another module just for retry, not to mention there are already 2 different modules now, axios-retry vs retry-axios.

Besides, thru my limited test, this issue https://github.com/axios/axios/issues/553 has not been fully fixed.



Answered By - Qiulang
Answer Checked By - Katrina (PHPFixing Volunteer)
  • Share This:  
  •  Facebook
  •  Twitter
  •  Stumble
  •  Digg
Newer Post Older Post Home

0 Comments:

Post a Comment

Note: Only a member of this blog may post a comment.

Total Pageviews

Featured Post

Why Learn PHP Programming

Why Learn PHP Programming A widely-used open source scripting language PHP is one of the most popular programming languages in the world. It...

Subscribe To

Posts
Atom
Posts
Comments
Atom
Comments

Copyright © PHPFixing