-
Notifications
You must be signed in to change notification settings - Fork 8
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
Added first draft of a media-player #46
Conversation
Since all this is just a POC as of now, I refrained of implementing it into the private-playlists as well as of now. If you agree that this is a good way to go, I'll start addressing the |
The one thing I stumbled with is the MediaPlayerInjectionKey. I don't quite like the name but I don't have a better idea either. I guess it would be more intuitive if I used Vue a lot. In general I think it's fine. |
I've just chosen it for a personal naming preference - not knowing if there is any tendency of naming in the eco-system. Maybe it's quite an OOP-inspired naming 😄 https://devrant.com/rants/502139/oop-programming-be-like |
I was more thinking to just call it MediaPlayer and make other exports private or protected. |
Don't know if this would work out well with lazy loading - haven't tried ... Maybe the player would then be a copy in each component we get in via ll 😓 EDIT: As of what I read online its about the same as using DI in other frameworks, which really seem to shine when having multiple implementations for the same interface... No objection from my side here ... could do some tests if needed to see if my first argument holds any water, but would just leave it as is if nobody has other objections... |
# Conflicts: # src/App.vue # src/main.ts # src/views/BrowseView.vue # src/views/Playlist/CuratedPlaylistDetails.vue
Codecov Report
@@ Coverage Diff @@
## main #46 +/- ##
=========================================
Coverage 100.00% 100.00%
=========================================
Files 3 3
Lines 71 71
Branches 5 5
=========================================
Hits 71 71 📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more |
# Conflicts: # src/App.vue
Seems like this somehow slipped in ... can be removed to reduce changes of this PR
This is a first version of how a media-player could look like - just a POC and some ideas of mine.
The player can be tested on the
browse
route, where I've added a new componenttemp-playlist
. As the comment in the file states, this is just here for testing purpose and should be removed as soon as we have a proper listing of tracks - therefore I've not taken the effort of building a well defined component there.I tried to decouple the media-player and the queue, as I see them as separate concepts where the one should not much relation to the other. This way we can have many "players" where only one of them is actively playing, another might be prefetching data.
Would be nice to hear your feedback on it.