A music player app that allows you to search for music by artist. Music source from iTunes affiliate API. Made using Flutter with simple clean architecture inspired by Reso Coder and Bloc state management by Felix Angelov. Design Inspired by Spotify.
|Search songs by artist||Play and pause song|
|Intial screen||Empty result||Connection error|
- Search song preview by the artist
- Play and stop a song
- Playing indicator
- Play song in the background
- Portrait lock
- Error handling includes empty results, server errors, and connection errors.
- You can run this app on Android API level 16 (Jelly Bean) or above.
In this project, I try to implement some stacks like
- Implement Clean architecture that inspired by reso coder
- Bloc state management using flutter_bloc
- implement simple atomic design
- Service Locator using get_it
- unit test using a build-in test kit from flutter and bloc test
- mocking using mocktail
- state logging using bloc observer
- handle debounce event.
- Before you begin, ensure you have installed flutter based on your operating system
- Android device or Android emulator with Android API level 16 (Jelly Bean) or above.
How to build
- Ensure you have flutter installed
- Clone this repository
git clone https://github.com/Muhibush/music_player.git
- Open projects on your IDE like Android Studio, Visual Code, etc..
- Open android simulator or connect your android device
flutter pub getto get all dependencies that are needed
- Use command
flutter runto build in debug mode or use
flutter run --releaseto build release mode.
How to run unit test
flutter testinside the project directory
- Generate coverage report using
flutter test --coverage, a coverage report seems to be generated into a file
If you want to contact me you can reach me at Instagram or Linkedin.