How to view css stylesheet injected by a Google Chrome extension using dev tools?

后端 未结 3 1379
粉色の甜心
粉色の甜心 2021-02-18 19:00

I\'m injecting a css file from my chrome extension using the manifest.json (full source):

  \"content_scripts\": [
    {
      \"matches\": [
        \"http://*/         


        
3条回答
  •  失恋的感觉
    2021-02-18 19:31

    Use the Chrome App and Extensions Developer Tool on an extension which injects CSS, such as Bootstrap Grid Overlay:

    the injected URL can be used on the console tab on the app to get the runtime URL using the getURL method:

    chrome.runtime.getURL("src/grid.css")
    

    and produce the source:

    References

    • Content Scripts - Google Chrome

    • chrome.runtime - Google Chrome

提交回复
热议问题