How to run Vimeo Videos?
prameetc opened this issue · 1 comments
prameetc commented
I have this Vimeo Link - https://player.vimeo.com/video/289535718
How do I run this video using this package?
I have Vimeo Pro account and API Key with me.
lyvwhyr commented
const VIMEO_ID = '179859217';
fetch(`https://player.vimeo.com/video/${VIMEO_ID}/config`)
.then(res => res.json())
.then(res => this.setState({
thumbnailUrl: res.video.thumbs['640'],
videoUrl: res.request.files.hls.cdns[res.request.files.hls.default_cdn].url,
video: res.video,
}));
then use that videoUrl variable in the package.
You will need to interact with Vimeo API yourself as this plugin won't automatically take care of it