import './bootstrap'
import React from 'react'
import { createRoot } from 'react-dom/client'
import { createInertiaApp } from '@inertiajs/react'

import LeaderboardPage from './Pages/Leaderboard/LeaderboardPage'

const pages = {
  'Leaderboard/LeaderboardPage': LeaderboardPage,
}

createInertiaApp({
  resolve: (name) => pages[name],
  setup({ el, App, props }) {
    const root = createRoot(el)
    root.render(<App {...props} />)
  },
})
