How matmyfta/geografitest works
Project type and purpose
• This is a SvelteKit–based single‐page web application (no custom backend).
• From src/routes/game and utils/GameController.js, it implements an interactive geography game: it loads GeoJSON region data, renders maps, and handles game rules in the browser.
File structure
• Top‐level config files (svelte.config.js, vite.config.js/ts, tsconfig.json, jsconfig.json, package.json) – define build and dev tools.
• src/ – your application source:
– app.html, app.css – global template and styles
– routes/ – SvelteKit page components (+layout.svelte, +page.svelte). “/game/+page.svelte” is the main game view.
– utils/ – client‐side services and controllers:
• GameController.js – orchestrates game state and user interactions
• MapService.js – loads and renders GeoJSON map layers
• RegionService.js – manages game logic per region
• geojson/adapters/ – adapter classes to transform raw .geojson files into a consistent internal format
• static/assets/private/ – raw .geojson files, served as static assets
• static/styles.css – global CSS
README for additional insights
• Default SvelteKit scaffolding – no extra server processes or microservices.
• All dynamic behavior lives client‐side under SvelteKit’s dev/prod server.
Essential detail checklist
• SvelteKit server role (dev vs. prod).
• Static GeoJSON asset store.
• MapService’s fetch calls and adapter transformations.