Skip to Content
0

Browser cache issue after any change in the UI

Apr 07, 2017 at 09:25 AM

561

avatar image

Hi experts,

I have made a custom SAP UI5 application in HCP. I am facing the browser cache issue in the application. Whenever I am doing any change in UI the changes are not reflected in the application. I need to do hard or empty cache reload to see the changes.

I am directly loading the component.js(not using index.html) file to load the application so I can't use the cache buster code(which is handling cache buster issue automatically) which we write in index.html to handle cache issue.

10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

3 Answers

Antonette Venter Apr 07, 2017 at 09:37 AM
0

Hi Vishal

This can be quite frustrating when developing apps. I always have console (f12 developer tools) open in my browser when I refresh apps. There is a setting under the "network" tab: "Always refresh from server" (IE) or "Disable cache" (Chrome). This forces the browser to load from the server instead of browser cache.

Hope this helps

Antonette

Show 1 Share
10 |10000 characters needed characters left characters exceeded

Hi Antonette,

Thanks for your suggestion.
I am also using the same approach when developing the application, but I just need the permanent solution for this issue.

0
Akhilesh Upadhyay Apr 07, 2017 at 11:23 AM
0

one html file must be using to run your app, that may be inside the test folder in project structure, check your app url to find html file and you can implement cache buster there.

Show 2 Share
10 |10000 characters needed characters left characters exceeded

Hi Akhilesh,

yes html file is there in my project structure, but I am using component.js to run the application in HCP. So whatever I am writing in html file it will not get excuted.

0

find out the proper one and write in that html file, will work.

0
Srikanth KV Apr 07, 2017 at 03:18 PM
0

check if this link helps

Show 2 Share
10 |10000 characters needed characters left characters exceeded

Yes this link have the cache buster code but that can only be written in index.html but I have already mentioned that I am not using index file to load the application. I am directly using component.js to load the application.

0

As there is no 'index.html' file, it means that your application is running inside another UI5 application/container like FIORI launchpad. In this case resolving cache should be the responsibility of parent container(FIORI launchpad) holding your application

0