JSPM

devtools-debugger

2.2.4
  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 15
  • Score
    100M100P100Q38813F
  • License MIT

监测浏览器打开debugger调试及debugger打开位置

Package Exports

  • devtools-debugger

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (devtools-debugger) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

devtools-debugger

Install 安装

    npm install devtools-debugger

使用方法

<script src="node_modules/devtools-debugger/index.js"></script>
<script>
    console.log('工具栏打开状态', window.devtools.open);
    console.log('工具栏方向', window.devtools.orientation);

    window.addEventListener('devtoolschange', function (e) {
        console.log('工具栏打开状态?', e.detail.open);
        console.log('工具栏打开状态?', e.detail.orientation);
    });
</script>

Support

  • Chrome DevTools
  • Safari DevTools
  • Firefox DevTools
  • Opera DevTools
  • Firebug
  • Firebug Lite