简体   繁体   English

chrome,javascript在两次运行之间不会更新

[英]chrome, javascript is not updating between runs

for example, if I were to have alert("hello world") during run 1, and then deleted it for run 2, the code would still during the run. 例如,如果我要在运行1中使用alert("hello world") ,然后在运行2中将其删除,则代码仍将在运行中。

this does not happen in IE, and I don't use firefox so I can't tell if it would happen there. 这在IE中不会发生,并且我不使用firefox,所以我无法确定它是否会在那发生。

is chrome for some reason caching my runs and not loading them in on each run? chrome是否出于某种原因缓存了我的跑步而不在每次跑步时都将其加载?

for reference my project is in .net 供参考,我的项目在.net中

May be you should disable the chrome's cache during development. 可能是您应该在开发期间禁用Chrome的缓存。

1.Open your chrome, in its menu , navigate View --> Developer --> Developer Tools 1.打开chrome,在其菜单中,导航至视图 -> 开发人员 -> 开发人员工具

2.In the DevTools panel , click the Setting button in the top right . 2.在“ DevTools”面板中,单击右上角的“ 设置”按钮。

在此处输入图片说明

3.Check the Disable cache (while DevTools is open) 3,检查禁用缓存(打开DevTools时)

在此处输入图片说明

4.Keep the DevTools opend , and refresh your page to check if your new code works. 4.保持DevTools opend打开 ,并刷新页面以检查新代码是否有效。

5.More details about the chrome DevTools , refer to Chrome DevTools Overview 5.有关chrome DevTools的更多详细信息,请参阅Chrome DevTools概述

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM