fixing bugs
This commit is contained in:
@@ -24,7 +24,6 @@ export default {
|
||||
const res = await fetch("/api/spotify/listening");
|
||||
if (!res.ok) throw new Error("Failed to fetch Spotify data");
|
||||
song.value = await res.json();
|
||||
console.log(data);
|
||||
} catch (err) {
|
||||
console.error(err);
|
||||
}
|
||||
|
||||
@@ -1,12 +1,12 @@
|
||||
<template>
|
||||
<div
|
||||
v-for="(song, idx) in played"
|
||||
:key="song.item.id || idx"
|
||||
:key="song.track.id || idx"
|
||||
class="spotify-now-playing"
|
||||
>
|
||||
<img :src="song.item.album.images[0].url" />
|
||||
<p><strong>Song:</strong> {{ song.item.name }}</p>
|
||||
<p><strong>Artist:</strong> {{ song.item.artists[0].name }}</p>
|
||||
<img :src="song.track.album.images[0].url" />
|
||||
<p><strong>Song:</strong> {{ song.track.name }}</p>
|
||||
<p><strong>Artist:</strong> {{ song.track.artists[0].name }}</p>
|
||||
<p>Is what im currently listening to rnrnrn ^_^</p>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
Reference in New Issue
Block a user