DEV Community

Discussion on: Clear Cache on build for React Apps.

Collapse
 
vishalvishalgupta profile image
vishalvishalgupta

Can you please check once again your implementation? The react web app gets reload only because of withClearCache's useEffect. The code is never going in refreshCacheAndReload. And also, if intentionally, I wanna get the code fall in refreshCacheAndReload function, It lets the UI into never ending rerendering. Please check your implementation and revert me back.
FYI, your buildDate in package.json and meta.json are always going to be same and if they are going to be same, then if (momLatestDateTime.isAfter(momCurrentDateTime)) {
is always going to give you false.

Collapse
 
ammartinwala52 profile image
Ammar Tinwala

Hi Vishal

I'm very sorry for such a late reply. Can you check the answer to Khorengrig that I just mentioned. It explained what exactly happens.

If you are still not clear then please email me ammartinwala52@gmail.com