ReactJS deployment on S3 bucket

0

I have tried to deploy a web application with the backend in Node.js and the frontend in React. The backend is deployed on an EC2 instance, and the frontend (React app) is hosted on S3. However, I am facing an issue where the routes in the React app are not working. The application successfully loads the index.html page, but after logging in, it fails to redirect to the dashboard. Does S3 only support React SPA?

posta 4 mesi fa278 visualizzazioni
1 Risposta
0

Hello.

It should be possible to run ReactJS on S3.
The following document describes how to run the sample, so I think it will be helpful.
https://docs.aws.amazon.com/prescriptive-guidance/latest/patterns/deploy-a-react-based-single-page-application-to-amazon-s3-and-cloudfront.html

profile picture
ESPERTO
con risposta 4 mesi fa
profile pictureAWS
ESPERTO
verificato 4 mesi fa

Accesso non effettuato. Accedi per postare una risposta.

Una buona risposta soddisfa chiaramente la domanda, fornisce un feedback costruttivo e incoraggia la crescita professionale del richiedente.

Linee guida per rispondere alle domande