vuejs / devtools-v6

⚙️ Browser devtools extension for debugging Vue.js applications.
https://devtools-v6.vuejs.org/
MIT License
24.68k stars 4.14k forks source link

vue devtools can not work #2195

Open IdealBoy709 opened 6 days ago

IdealBoy709 commented 6 days ago

Vue devtools version

6.6.4

Link to minimal reproduction

*

Steps to reproduce & screenshots

I have installed many plugins on my Chrome for Mac, which are useful and necessary, and I have installed the 6.6.4 version of vue devtools on my computer. At present, when running the old vue2 project on my Chrome, the devtools cannot be automatically called up, but the vue3 project seems to be normal. Through breakpoint debugging, I found that the execution order of the local devtools and the execution order of vue.esm.js seemed to be reversed, resulting in the failure to find the window.__VUE_DEVTOOLS_GLOBAL_HOOK__ object when vue.esm.js initialized devtools, so the developer tools could not be displayed normally. When I use other browsers, I first execute the hijacking injection of window.__VUE_DEVTOOLS_GLOBAL_HOOK__, and then execute init in the emit of devtools in vue.esm.js. 1731687761879

What is expected?

Old vue2 projects can also call up devtools normally

What is actually happening?

The development environment normally invokes vue devtoolsThe development environment cannot call up vue devtools in the vue2 project, but everything is normal in the vue3 project

System Info

System:
    OS: macOS 15.2
    CPU: (12) x64 Apple M2 Max
    Memory: 727.14 MB / 64.00 GB
    Shell: 5.9 - /bin/zsh
  Binaries:
    Node: 14.20.0 - ~/.nvm/versions/node/v14.20.0/bin/node
    Yarn: 1.22.22 - /opt/homebrew/bin/yarn
    npm: 6.14.17 - ~/.nvm/versions/node/v14.20.0/bin/npm
    Watchman: 2024.11.04.00 - /opt/homebrew/bin/watchman
  Browsers:
    Chrome: 131.0.6778.70
    Edge: 130.0.2849.80
    Safari: 18.2

Any additional comments?

No response