import { useState, useEffect } from 'react' const baseUrl = typeof window !== 'undefined' ? window.location.origin : process.env.VITE_VERCEL_URL || 'http://localhost:5173'; // Fallback for your server env export function Welcome() { const [stats, setStats] = useState([]); const [skills, setSkills] = useState([]) useEffect(() => { fetch(`${baseUrl}/characters/collateral/stats.json`) .then(r => r.json()) .then(j => setStats(j)); fetch(`${baseUrl}/characters/collateral/skills.json`) .then(r => r.json()) .then(j => setSkills(j)) }); return (
STAT SCORE
INT {stats.int}
REF {stats.ref}
DEX {stats.dex}
TECH {stats.tech}
COOL {stats.cool}
WILL {stats.will}
LUCK {stats.luck}/{stats.luck}
MOVE {stats.move}
BODY {stats.body}
EMP {stats.emp}/{stats.emp}
/*
React Router React Router
*/ ); } const resources = [ { href: "https://reactrouter.com/docs", text: "React Router Docs", icon: ( ), }, { href: "https://rmx.as/discord", text: "Join Discord", icon: ( ), }, { href: "https://rmx.as/discord", text: "Join Discord", icon: ( ), }, ];