src/components/App/App.js
// Filters out the given track and updates the state
Filters out the given track and updates the state
Filters out the given track and updates the state
removeTrack(track) {
        let playlistTracks = this.state.playlistTracks;
        playlistTracks = playlistTracks.filter(savedTrack => savedTrack.id !== track.id);
        this.setState({playlistTracks: playlistTracks});
    }
removeTrack ( track ) { let playlistTracks = this . state . playlistTracks ; playlistTracks = playlistTracks . filter ( savedTrack => savedTrack . id !== track . id ) ; this . setState ( { playlistTracks : playlistTracks } ) ; }
Filters out the given track and updates the state
Filters out the given track and updates the state