import Image from 'next/image'
import Link from 'next/link'
import React from 'react'
import useSWR from 'swr'
import { socials } from 'components/data/socials'
import { Icon } from 'components/Icon'
import { Footer } from 'components/Footer'
import { Loading } from 'components/Loading'
import { Toaster } from 'react-hot-toast'
import { FaSpotify } from 'react-icons/fa'
const fetcher = (url: RequestInfo) => fetch(url).then(r => r.json())
export default function() {
const { data: spotify } = useSWR('/api/spotify', fetcher, { refreshInterval: 1000 })
if(!spotify) return
{ Math.floor((new Date().getTime() - new Date('2004.07.22').getTime()) / (1000 * 60 * 60 * 24 * 365.25)) } yrs old system administrator and student from Hungary
Listening to { spotify.song ? { spotify.song.title || 'nothing' } : nothing }