- Show recommended tracks based on users' top items
- Search for tracks
- Create playlist
- Add tracks to your playlist
- See all of your playlist
- See tracks inside of your playlist
- See your account profile picture and display name
- Open tracks & playlist in Spotify with one click
- Create React App to initialize the project.
- Written in Typescript
- React Redux for state management
- React Router for routing
- Jest, for testing
- MSW, for creating API mock
- Deployed on Vercel
- Use redux to store token, user profile, and selected tracks data.
- Implements Spotify API for searching tracks, get users' top items tracks, creating playlist, adding tracks to playlist, getting all of your playlist, getting all contents of your playlist, and get your Spotify profile data.
- Use react router with private route for authentication verification.
- Implements several types for typescript.
- Create unit and integration test. Use MSW to test API calls.
- Spotify account (Free/Premium)
- Setting up Spotify Application in Spotify Developer Dashboard
- NodeJS installed in your machine
- Git
- Clone repo to your local machine. After it finished, open the folder and install project dependencies. You can do this from your command line/terminal :
# Clone this repository
$ git clone https://github.com/irfan44/generasi-gigih-homework.git
# Go to repository folder
$ cd generasi-gigih-homework
# Install dependencies
$ npm i
- Insert your spotify key to
REACT_APP_SPOTIFY_CLIENT_ID
and redirect tohttp://localhost:3000/
forREACT_APP_BASE_URL
in.env
file. Make sure that you've added the redirect URL to your application in Spotify Developer Dashboard
# .env example
REACT_APP_SPOTIFY_CLIENT_ID=9090asdasdczsda9a10ak12eqws12smx
REACT_APP_BASE_URL=http://localhost:3000/
- Run the app
$ npm start
- Open
http://localhost:3000
to view the app in your browser
Please let me know if there is anything I missed. :-)