Can obtain videoId
using
videoId () {
return this.video_url.match(/(?:https?:\/\/)?(?:www\.)?youtu(?:be)?\.(?:com|be)(?:\/watch\/?\?v=|\/embed\/|\/shorts\/|\/)(\w+)/)[1]
}
Can check if valid Youtube link using
return value.match(/(?:https?://)?(?:www.)?youtu(?:be)?.(?:com|be)(?:/watch/??v=|/embed/|/shorts/|/)(\w+)/)