Avatar of Michael Sterling
Michael Sterling
Flag for United States of America asked on

What are the pros and cons of making your api call from within your react app verses creating a separate api application?

I'm new to creating/using APIs and React, so can someone give me some pros and cons (or links to articles that detail the pros and cons) of making your api calls directly in your react app vs. creating a separate api application?
ReactJavaScript* ReactJS

Avatar of undefined
Last Comment
Michael Sterling

8/22/2022 - Mon
ASKER CERTIFIED SOLUTION
Chris Stanyon

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
GET A PERSONALIZED SOLUTION
Ask your own question & get feedback from real experts
Find out why thousands trust the EE community with their toughest problems.
Michael Sterling

ASKER
I see now that my question didn't make as much sense as I originally thought. But to your point (and mine I think): React is going to make the API call, the API itself will be written OUTSIDE of the react application as it would have to be, right? I think I confused myself about where each application would/could live i.e.: both applications on the same server vs. on two different servers. So in the main regard, thank you for your response and in a lessor regard, never mind haha!
SOLUTION
Chris Stanyon

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
GET A PERSONALIZED SOLUTION
Ask your own question & get feedback from real experts
Find out why thousands trust the EE community with their toughest problems.
Michael Sterling

ASKER
"Getting your head around all the different moving parts of more complex applications can be quite tricky :) "

Man you ain't kiddin! Thanks again!
Your help has saved me hundreds of hours of internet surfing.
fblack61