LonelyCpp / react-native-youtube-iframe

A wrapper of the Youtube-iframe API built for react native.
https://lonelycpp.github.io/react-native-youtube-iframe/
MIT License
603 stars 153 forks source link

feat: add a setHeight method to the player ref to resize it #201

Open Kloadut opened 2 years ago

Kloadut commented 2 years ago

I wanted to resize the player on the fly, for example to support vertical videos like https://youtu.be/GeYK9JdPVMw.

I added a new method to the YoutubePlayer ref in order to do that. Let me know if that's a feature you'd be interested in and if there's anything you'd like me to change.

Cheers!

LonelyCpp commented 2 years ago

Hey, terribly sorry for the late reply.

This is a good feature to have, but would be better to directly set the height prop on the component.

We'll have to make this https://github.com/LonelyCpp/react-native-youtube-iframe/issues/13#issuecomment-611753123 into a toggleable prop. after enabling this, users can simply change the height and width prop to get the desired effect

LonelyCpp commented 2 years ago

let me know if you wanna work on this, else I'll take it up

Kloadut commented 2 years ago

Hola! No worries :)

Work on it if you find time