SpotifyShuffler is written without any AppDelegate
or SceneDelegate
.
In other words, SpotifyShuffler is pure SwiftUI
.
SpotifyShuffler showcases the usage of MVVM
by using both Combine
and SwiftUI
.
- In
Constants.swift
add your own values in:redirect
,spotifyClientID
,spotifyCLientSecretKey
. - In the
Info.plist
file add your own values in:CFBundleURLName
andCFBundleURLSchemes
. - The application will only run if you run it on a physical device.
- Prompts the user to connect with Spotify.
- Fetches the users playlists and presents them to the user in a list.
- The user can then whichever playlist they want to shuffle.
- The selected playlist is then presented in a new view to the user.
- All of the current songs from the selected playlist are loaded into the view.
- As the songs are being loaded they are added in a dynamic list.
- Showcasing the number of songs that have loaded out of the total amount of songs in the playlist.
- When all of the songs have been fetched the following occurrs:
- The user is presented with 3 buttons.
Resume
,Shuffle
,Pause
- By pressing
Shuffle
an entirely random song will be played from the selected playlist. - By pressing
Shuffle
again another entirely random song will be played without it being the prior shuffled song.
- The user is presented with 3 buttons.
- All of the current songs from the selected playlist are loaded into the view.