I’ve been refining this project a lot for my own use and would like to share it with you, but I suggest it should be an upgraded major version, since I let myself break some API to have better organization and understanding of this library. Plus because a lot is rewritten, It will be probably better to handle it on a different branch and an alpha version on npm (1.0.0-alpha.1).
Stuff added:
videoIds
: option to load an array of playable video IDsplaylistId
: option to load a YouTube playlist’s IDpreviousVideo()
/nextVideo()
: methods for multiple videosplayVideoAt(index)
: play the video ofindex
place invideoIds
orplaylistId
videoIndex()
: a promise method to get the index of the currently played video out of multiple videos- Smooth linking with
react-native link
andrnpm link
for both platforms. No other installation steps. - Updated README with less ambiguity about props (Differences between iOS and Android) and also explanations of known issues I have discovered while working.
- Native code refactored and build warnings omitted
- Started tracking and pinning peerDependency of RN
iOS Improvements
- Instead of reloading for every prop change, the inner WebView holding the YouTube iFrame now loads once and is updated via methods
- Native code refactored to use newer events passing, former is being deprecated
- Updated files from youtube-ios-player-helper to 0.1.6
Android improvements
- Refactored layouting of the
YouTubePlayerFragment
instances to prevent fatal error when multiple instances override each other if succeed each other in RN #64
Upgraded example project
I’ve totally rewritten the example project to showcase all the added functionality, plus it was upgraded to RN 0.37. Also the example project is now linked to the working directory of the library so it can be used as a developing project, with a simple npm install
command to update the underlying code.
The repository can be found here.
Lets open a v1 branch and start publishing this to npm
Thanks
Issue Analytics
- State:
- Created 7 years ago
- Reactions:7
- Comments:28 (17 by maintainers)
Top GitHub Comments
@jujumoz any plan on incorporating this as a next version branch?
Other than tons of refactoring, I think the work I did here on playlists, updated example / development app, and simplified installation is extremely valuable to the freshness of this project.
@vesper8 I would gladly take a maintainer role in this repository. I think it can be maintained much better than just be patched with pull-request everytime. All depends on the owners @julien-inprogress