import React, { useState, useEffect } from 'react'; import axios from 'axios'; import { useRouter } from 'next/router' function App (props) { const uuid = props; const [data, setData] = useState({ hits: [] }); useEffect(() => { const fetchData = async () => { const result = await axios( 'https://minecraft.yude.jp/group/' + uuid.uuid, ); setData(result.data); }; fetchData(); }, []); if (data === undefined || data === null){ return

}else { if (data.toString() == "staff") { return Staff } else { return <> } }; } export default App;