I’m working on an extension that edits specifically you-tube video pages so i added the following to my manifest.json:
"content_scripts": [ { "matches": ["*://*.youtube.com/watch*"], "js": ["src/content/blockComments.js"] } ]
However i noticed that the content script doesn’t always load in the you-tube page and after some testing i found out how to make it appear:
- Open the video page in a tab making it’s original url match the one for the content script.
- If i entered the video page where the original url of the tab wasn’t a youtube video refresh the tab and content script will now be added.
I tested this with simple logs and got the same results, is this intentional or a weird bug or am i missing something?