Hello, I’m trying to host my React static website on digital ocean using App Platform. I’ve integrated it with gitlab, it deploys correctly but once I go and visit the website the page is completely blank.
The only error showed is that it cannot find the favicon on the public directory but other than that nothing else. Moreover if I host it on Firebase Hosting it works without issues.
I’ve followed different guides and looked all over the internet but couldn’t find anything.
Currently I’m using react-router-dom as for Routes with HashRouter
the command to run it is: npm run build
could anyone help me on this, I think I’m stuck at this point
–EDIT–
After waiting 30 minutes it got fixed by itself, now the page loads correctly. Of course before checking I cleaned my browser cache multiple time, is DigitalOcean caching the page?
This textbox defaults to using Markdown to format your answer.
You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!
With static sites, the page content is cached at the CDN level for 24 hours and at the browser level for 10 seconds (using the following cache-control header: public,max-age=10,s-maxage=86400).
However, at the end of each app deployment, the CDN cache is purged, so practically speaking, each page is cached for only 10 seconds.
If you see incorrect caching behavior, please open a support ticket and include a full request log with both the request and response headers (you can find them in your browser’s dev tools) + any other information that might be helpful.
Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.
Full documentation for every DigitalOcean product.
The Wave has everything you need to know about building a business, from raising funding to marketing your product.
Stay up to date by signing up for DigitalOcean’s Infrastructure as a Newsletter.
New accounts only. By submitting your email you agree to our Privacy Policy
Scale up as you grow — whether you're running one virtual machine or ten thousand.
Sign up and get $200 in credit for your first 60 days with DigitalOcean.*
*This promotional offer applies to new accounts only.