0

After updating a static resource and importing it using import nameOfResource from "@salesforce/resourceUrl/nameOfResource";, only the FIRST version is what is obtained and not any subsequent updated versions, even after emptying the browser cache and performing a hard reload.

There is a solution with Aura How can I refresh the cache for static resources in Communities?

But is there an LWC solution for this? The link above only applies to Aura, but how can I obtain the latest version of the static resource for LWC in Community/Experience pages?

1 Answer 1

0

Communities cache all the used resources (scripts, etc) that are presented to the client. You need to actually Publish the site to get any new changes to be updated.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.