Built with Astro, bundled with Bun and using data from the Taso API by TorneoPal.
All commands are run from the root of the project, from a terminal:
Command | Action |
---|---|
bun install |
Installs dependencies |
bun run dev or bun run start |
Starts local dev server at localhost:4321 |
bun run build |
Build your production site to ./dist/ |
bun run preview |
Preview your build locally, before deploying |
bun test |
Run unit tests |
bun run astro ... |
Run CLI commands like astro add , astro check |
bun run astro -- --help |
Get help using the Astro CLI |
Read access to the Taso API is needed to display fixtures. More info on the API in the Tason rajapinta documentation (in Finnish).
Required keys and configuration are defined as env variables:
TORNEOPAL_API_KEY
: the club specific API key (can be requested in Taso)TORNEOPAL_CLUB_ID
: the Taso id of the club to fetch the fixtures of (the owner of the provided API key). You can find this for example by searching for the club in Tulospalvelu. The id is the URL for a club (for example,79
for Helsingin Ponnistus)TORNEOPAL_COMPETITION_ID
: the id of the competition to fetch the fixtures of. Typically, there's a competition for every area, sport and season. E.g.etejp24
whereete
is for "eteläinen",jp
is for "jalkapallo" (football, as opposed to futsal) and24
is for season "2024"MOCK_TORNEOPAL_REQUESTS
: whentrue
, bypass all API requests and use the mock fixtures insrc/test/fixures
instead (usually during development to avoid redundant calls to the API)
You add env vars via an .env
file in the project root. Example:
TORNEOPAL_API_KEY=abcde12345
TORNEOPAL_CLUB_ID=79
TORNEOPAL_COMPETITION_ID=etejp24
MOCK_TORNEOPAL_REQUESTS=false