Relative Content

Tag Archive for cachingvitebrowser-cacheastrojsmicro-frontend

Astro and react app not automatically showing new releases until user hard reload/clear cache

I have an app built-out and functioning well, built using React, Vite, and served by Astro. The build files are sent to an S3 bucket which is then deployed to a Cloudfront. To clarify, this is a microfrontend app, with the React child app being served statically by the Astro parent app.
Mainly with styling changes, users would have to hard reload/clear cache to see new releases. For example, I have implemented a sort of dynamic color-changing schema, that users can only see if they hard reload/clear cache. This implementation works fine in an incognito browser, which leads me to thinking it is a cache issue.
The expected behaviour is after build and push, users should be able to see the new changes on the site without having to clear cache/reload, which is not what is happening.
Has anyone run into this issue?