blob: 8b31d543223df78c98af6fd745d39a04a506fcde (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
|
import { createRoot } from 'react-dom/client';
import App from './game/App.jsx';
const url = new URL(window.location.href);
const path = url.pathname;
const match = path.match(/\/golf\/(\d+)\/(a|b)\/$/);
if (match) {
const gameId = match[1];
const team = match[2];
createRoot(document.getElementById('app')).render(<App gameId={gameId} team={team} />);
}
|