-
Notifications
You must be signed in to change notification settings - Fork 2.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: add plugins management #3909
feat: add plugins management #3909
Conversation
…oplayerView code size
…ideo # Conflicts: # android/src/main/java/com/brentvatne/exoplayer/ReactExoplayerViewManager.java # src/Video.tsx
…fix/avoidVideoResizingFlickering # Conflicts: # .github/ISSUE_TEMPLATE/bug-report.yml
* fix: ensure player doesn't start when view is unmounted
…ideo into feat/addAnalyticsPlugManagement # Conflicts: # android/src/main/java/com/brentvatne/exoplayer/ReactExoplayerView.java # examples/basic/ios/Podfile.lock
…/react-native-video into feat/addAnalyticsPlugManagement # Conflicts: # examples/basic/ios/Podfile.lock
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code and "idea" looks good to me 👍
I am also thinking about changing naming from "analytics plugins" -> "plugins" bcs this will allow to do way more things - not just analytics (or at last I think that)
I have not tested it yet - but will try do let you know to end of the week
I agree for the renaming, I will do it. I tried yesterday to implement a thumbnail preview feature with the plugin system, but the sample I found are not so simple (thumbnails in mjpeg format). I will try again in few days ! |
@freeboub I have tested this PR (via example plugin - thanks for making it 😄) and it works on iOS and Android - Great Job! |
…feat/addAnalyticsPlugManagement
…ideo into feat/addAnalyticsPlugManagement # Conflicts: # examples/basic/ios/Podfile.lock # examples/basic/ios/videoplayer.xcodeproj/project.pbxproj # examples/basic/tsconfig.json
I did the change! THanks |
…ideo into feat/addAnalyticsPlugManagement
Summary
Create a plugin system to allow other package to retrieve the player handle.
These side package can mainly handle analytics events
Motivation
Add an easy way to track analytics management.
will answer to discussion: #3564
Changes
on android and IOS,
Add ReactNativeVideoManager, singleton to access to the package entry point
Each view register themselves in ReactNativeVideoManager
Add apis to register plugins in ReactNativeVideoManager
When creating a new player plugin system will be called (see documentation)
A sample plugin has also been added to test
Test plan
N/A