Embed YouTube videos/streams, or Twitch streams.
The screen ratio of the video: 16:9
or 4:3
The YouTube/Twitch URL of the video to play.
(Optional)
Let's the user set a customized thumbnail for the video.
String
; Links must be https://
and must either be a youtube, twitch, soundcloud, spotify
.
feature.get('url')
// returns: "https://..."
feature.set({'url':"https://www.youtube.com/?v=..."})
""
String
; Links must be https://
and must either be a .png,.gif,jpg
.
feature.get('previewUrl')
// returns: "https://..."
feature.set({'previewUrl':"https://..."})
""
feature.play()
plays the video
feature.pause()
pauses the video