如何强制Chrome的脚本调试器重新加载JavaScript? [英] How to force Chrome's script debugger to reload javascript?

查看:606
本文介绍了如何强制Chrome的脚本调试器重新加载JavaScript?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我真的很喜欢在chrome调试器中编辑javascript的能力,但是我发现让调试器从服务器重新获取JavaScript可能会有问题。

I really like the ability to edit javascript in the chrome debugger however, I find that it can be really problematic getting the debugger to re-fetch the JavaScript from the server.

有时我必须尽快关闭调试器并重新加载框架才能正常工作 - 但其他时间(在发生这种情况时无法确定dI)我必须清除临时Internet缓存。有时我发誓我必须完全关闭Chrome,然后清除缓存,然后在调试器最终显示最新的脚本之前加载页面。

Sometimes I have to go as far just closing the debugger and reloading the frame works OK - but other times (an dI cannot pin down under what conditions this occurs) I have to clear my temporary internet cache. Sometimes I swear I have to close chrome completely, then clear the cache and then load the page before the debugger finally shows me the most up-to-date script.

(注意:Web服务器没有缓存脚本)

(NB. There is no caching of the script by the web server)

我想知道是否有人知道一种简单快捷的方式告诉调试器使其所有的javascript失效并在页面重新载入时重新获取所有内容?

I was wondering if anyone knew of a quick and easy way to tell the debugger to invalidate all its javascript and fetch it all anew on page reload?

推荐答案

在开发脚本时,请尝试禁用Chrome缓存:

While you are developing your script, try disabling the Chrome cache:

当你重新加载页面,JavaScript现在应该刷新。

When you reload the page, the JavaScript should now get refreshed.

这篇关于如何强制Chrome的脚本调试器重新加载JavaScript?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆