【问题标题】:Do we have any javascript function with html where we can open the developer tool in the Chrome browser automatically?我们是否有任何带有 html 的 javascript 功能,我们可以在 Chrome 浏览器中自动打开开发人员工具?
【发布时间】:2020-05-14 20:09:08
【问题描述】:
<body>

<p>A function is triggered when the user is pressing a key in the input field.</p>

<input type="text" onKeyPress="myFunction()">

<script>
function myFunction() {
  alert("You pressed a key inside the input field");
}


</script>

</body>

在我需要在输入框中按 f12 的地方找到此代码,如果有任何代码可以自动执行此操作,请告诉我(当 chrome 自动打开时,开发人员工具应该打开)

【问题讨论】:

标签: javascript google-chrome console automated-tests google-chrome-devtools


【解决方案1】:

据我所知,如果有人提议将此作为一项功能,它可能会被视为安全风险。

【讨论】:

    猜你喜欢
    • 2016-07-22
    • 2014-02-20
    • 2023-01-25
    • 2015-11-02
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多