-
Notifications
You must be signed in to change notification settings - Fork 889
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update copy/open YT video in playlist view to have playlist ID when present #2848
Update copy/open YT video in playlist view to have playlist ID when present #2848
Conversation
// `playlistId` can be undefined | ||
if (this.playlistId && this.playlistId.length !== 0) { | ||
// `index` seems can be ignored | ||
return `https://www.youtube.com/watch?v=${this.id}&list=${this.playlistId}` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The shortened, https://youtu.be does also support playlists:
https://youtu.be/watch?v=${this.id}&list=${this.playlistId}
e.g.
https://youtu.be/watch?v=NWsMzSe5gLw&list=PL8mG-RkN2uTyfj8UNijuKK6Y38Cz7eQKJ
Whether the slightly shorter url matters is up to you; but at least then you would get the same domain back from this function regardless of playlist or not.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for letting me know
Will update soon
I was just copying this from an existing implementation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I found out that
https://youtu.be/${this.id}?list=${this.playlistId}
also works
https://youtu.be/bStmUUGMA0A?list=PLt6FSN4PoPuSzKNYTjGpv133iaK_i2JyZ
Gonna update to that
6314978
to
ca7c0b4
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Tested locally
@ChunkyProgrammer @efb4f5ff-1298-471a-8973-3d47447115dc we need your reviewing powers 🦸 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fast charging enabled!
Update copy/open YT video in playlist view to have playlist ID when present
Pull Request Type
Related issue
Similar to #1258
Description
Same as title
Screenshots
Testing
A
B
Only playlist view and playlist in video playing view are tested by me, please test more views~
Desktop
Additional context
I found that this feature is absent when I try to copy a video URL with playlist for non current playing video