Skip to content
Discussion options

You must be logged in to vote

Use :match-path(...) if you want to apply cosmetic filters according to URL path in the address bar:

music.youtube.com###player:matches-path(/^\/(?!watch)/)

Your filter is meant to apply only when the a navigation to a webpage which matches your regex occurs, not when the webpage visually update the URL address without navigation occurring.

One issue though is that the current :matches-path implementation doesn't react to URL address change events, because this was not available in browsers at time of :matches-path implementation. I will revise the implementation to now rely on navigation events. For now the workaround is to force refresh of procedural filters on attribute changes:

music…

Replies: 2 comments

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Answer selected by gothic-bum
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants
Converted from issue

This discussion was converted from issue #4100 on August 29, 2026 13:24.