Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to connect react native app to python?

I would like to use python as part of a react-native project which handles heavy algorithms. However, as many have suggested, it is not recommended to do that, but simply create an API for the python.

Now firstly, I'm confused by the term "create an API", what does that mean? Is it to use something like firebase that deals with backend, and then simply use firebase api?

like image 641
Jamie Avatar asked Nov 25 '25 17:11

Jamie


1 Answers

What I know (and I really don't know much) is to keep your frontend separate from your backend.

You can create the frontend React components in React. You also create API routes to your backend using e.g. python, flask, ... (firebase is a good option). Then you make HTTP requests from your frontend to your backend API to connect them together.

like image 123
Behnam Kamrani Avatar answered Nov 28 '25 06:11

Behnam Kamrani



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!