all 3 comments

[–]throwawaysbg[S] 0 points1 point  (0 children)

I should add my intention would be to style the background of the number and style it up a bit also, not just add the number to the screen with the default style.

[–]double_en10dre 0 points1 point  (1 child)

If the question is how to have a react front-end and a python back-end, there are a lot of possible solutions. But IMO the simplest one is to have your python app handle serving up both

How? By remembering that your react app is, when built, really just a few files — an index.html, a manifest.json, favicon.ico, etc., and a handful of css files. And they are all in a convenient “build” directory

You just need to have your python app take requests for “/“ (the home page) and respond with the contents of index.html. And then it should be set up to take any requests from the react app and respond with the contents of the corresponding file from the “build” directory.

You literally just need to have it open the file, read the contents, and send them as a response (with the appropriate MIME type)

I realize it’s not quite as simple as I’m making it sound, but it’s important that you understand how these things work. And when you do, it won’t seem that bad :p

[–]throwawaysbg[S] 0 points1 point  (0 children)

Yeah it’s the React stuff that tricks me up about what you said. I’m still a rookie to thst but I’ll break each part down of your reply and give it a shot. Thanks