File not updating on localhost

℡╲_俬逩灬. 提交于 2019-12-01 16:56:23

问题


I am pulling my hair here. I think I am falling into som really basic stuff but here is my error. I have built a simple webpage with the following "tree-view".

in my readjson.js I read from my json-file stored in json/label.json. However!

Even if I have updated my json-file it reads the FIRST version of the json-file when I started. Using Google Chrome and have tried to refresh the browser, clean my build an so on. Still wont update the json-file on localhost.

Have anyone else run into this and how do I solve it?


回答1:


Have you tried to bring up the developer console (ctr shift j) and right click on the refresh icon using the "Empty Cache and Hard Reload" option?




回答2:


Ctrl + Shift + Del -> Clear all cached data*

Then Ctrl + F5 should be enough.

EDIT: *In the newer versions of browsers clear only files and images cache.




回答3:


On Mac you right click the reload button and click "Empty Cache and Hard Reload". Sometimes, though, it's enough to just do a "Hard Reload" (cmd + shift + R).




回答4:


Right click on console and clear console history and right click on refresh button on your browser and hard reload.




回答5:


The problem is that Chrome is reading the data from cache files. You should:

  1. Clear cookies and cache files.
  2. Reload the page.

It worked for me.



来源:https://stackoverflow.com/questions/25723801/file-not-updating-on-localhost

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!