You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

Chrome扩展Manifest V3无Inspect Views选项问题咨询

Chrome扩展Manifest V3无Inspect Views选项的解决办法

你的扩展采用Manifest V3规范,该版本用Service Worker取代了Manifest V2的背景页,因此原有的「Inspect Views」入口不再显示,调试入口已调整位置,具体操作如下:

调试Service Worker(background.js)

  • 打开chrome://extensions/,确保开启「开发者模式」
  • 找到你的扩展,在「Service Worker」区域点击「Inspect」链接(部分Chrome版本显示为小检查图标)
  • 或者直接打开chrome://inspect/#service-workers,找到对应扩展的service worker,点击「inspect」进入调试

调试Popup页面

点击扩展图标打开popup后,右键点击popup内部区域,选择「检查」即可打开DevTools调试popup.html及相关脚本

调试Content Script(content.js)

打开匹配https://*/*的目标网页,打开网页自带的DevTools:

  • 切换到「Sources」标签,在左侧「Content scripts」目录下找到你的扩展的content.js
  • 或者直接在「Console」标签里调试,content script的日志会在此处输出

附你的manifest.json配置:

{    
  "name": "hoko's ext",    
  "description": "my ext",    
  "version": "1.0",    
  "manifest_version": 3,    
  "action": {        
    "default_popup": "popup.html"      
  },      
  "permissions": [        
    "activeTab"      
  ],      
  "background": {        
    "service-worker": "background.js",        
    "type": "module"      
  },      
  "content_scripts": [        
    {          
      "matches": ["https://*/*"],          
      "js": ["content.js"]        
    }      
  ]  
}

内容的提问来源于stack exchange,提问作者Hoko L

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.08.21 17:48:11