// Base layout
import Layout from "../../components/Layout"
// React
import { useRouter } from 'next/router'
// Data fetching
import Players from '../../components/Minecraft/Players'
import PlayerName from '../../components/Minecraft/PlayerName'
import useSwr from 'swr'
const fetcher = (url) => fetch(url).then((res) => res.json())
export default function UUID() {
const router = useRouter()
const { uuid } = router.query
const { data, error } = useSwr(
router.query.id ? `/api/user/${router.query.id}` : null,
fetcher
)
if (error) {
return (
<>
エラーが発生しました。
>
)
}
if (!data) {
return (
<>
>
)
}
return (
<>
+ " - " + "プレイヤー情報"}>
>
)
}