Skip to content

Commit

Permalink
Merge pull request #1 from Abhi011999/Abhi011999-yt-music-shorts
Browse files Browse the repository at this point in the history
Aded support for Youtube Music and Shorts URLs
  • Loading branch information
Abhi011999 authored Sep 19, 2022
2 parents fef473e + ab37c57 commit e0bb84e
Showing 1 changed file with 4 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -161,6 +161,10 @@ class YoutubePlayer extends StatefulWidget {
for (var exp in [
RegExp(
r"^https:\/\/(?:www\.|m\.)?youtube\.com\/watch\?v=([_\-a-zA-Z0-9]{11}).*$"),
RegExp(
r"^https:\/\/(?:music\.)?youtube\.com\/watch\?v=([_\-a-zA-Z0-9]{11}).*$"),
RegExp(
r"^https:\/\/(?:www\.|m\.)?youtube\.com\/shorts\/([_\-a-zA-Z0-9]{11}).*$"),
RegExp(
r"^https:\/\/(?:www\.|m\.)?youtube(?:-nocookie)?\.com\/embed\/([_\-a-zA-Z0-9]{11}).*$"),
RegExp(r"^https:\/\/youtu\.be\/([_\-a-zA-Z0-9]{11}).*$")
Expand Down

0 comments on commit e0bb84e

Please sign in to comment.