youtu.be seems to have is parameter in url when using mobile app

Open Beginner friendly
#202 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
1/5
Estimated time
Under an hour
Newbie friendliness
82/100
Issue type
Feature
Clarity
Clearly specified
Activity status
Quiet
Tech stack
javascript
Domain
security

Research direction

Start with the YouTube entry in data.min.json and compare its existing rules with the suggested addition. Add the mobile-app parameter to the listed YouTube rules, then verify that URLs containing it are covered without changing the existing exceptions or redirections.

Written by the indexing model from the issue text.

Description

Just fyi. I utilised your good blocklist in my more manual static web page based approach and immediately spotted that youtube mobile app uses is -parameter and pc browser uses si -parameter. So the data.min.json spots the latter but not the former.

Suggested edit:
Now:
"youtube": { "urlPattern": "^https?:\\/\\/(?:[a-z0-9-]+\\.)*?(youtube\\.com|youtu\\.be)", "completeProvider": false, "rules": [ "feature", "gclid", "kw" , "si", "pp" ], "referralMarketing": [], "rawRules": [], "exceptions": [ "^https?:\\/\\/(?:[a-z0-9-]+\\.)*?youtube\\.com\\/signin\\?.*?" ], "redirections": [ "^https?:\\/\\/(?:[a-z0-9-]+\\.)*?youtube\\.com\\/redirect?.*?q=([^&]*)" ], "forceRedirection": false },

Suggested modification
"youtube": { "urlPattern": "^https?:\\/\\/(?:[a-z0-9-]+\\.)*?(youtube\\.com|youtu\\.be)", "completeProvider": false, "rules": [ "feature", "gclid", "kw" , "si", "is", "pp" ], "referralMarketing": [], "rawRules": [], "exceptions": [ "^https?:\\/\\/(?:[a-z0-9-]+\\.)*?youtube\\.com\\/signin\\?.*?" ], "redirections": [ "^https?:\\/\\/(?:[a-z0-9-]+\\.)*?youtube\\.com\\/redirect?.*?q=([^&]*)" ], "forceRedirection": false },

If you want to protect against links sent from smartphone apps this should be added too at some point.

Ps. thanks for really good blocklist! It made my day.

Dominant language
JavaScript
Stars
252
Forks
79
PR merge metrics
No merged PRs in 30d

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from ClearURLs/Rules

All issues in ClearURLs/Rules

Similar issues

More JavaScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.