Skip to content
This repository has been archived by the owner on Sep 12, 2024. It is now read-only.

Team-SMP/teamsmp-web-again

Repository files navigation

Team SMP Website (again)

Built with Astro badge

This is the new version of the Team SMP Website, completely rebuilt from the ground up using Astro.

Useful for Collaborators

All commands are run from the root of the project, from a terminal, for example, using the VS Code integrated terminal, when opened from the workspace file. Some commonly used commands are listed in the table below.

Some commands are also available as VS Code tasks, executable by opening the command pallete (CTRL+SHIFT+P) and searching for "run task". Find the one named "Tasks: Run Task" and press ENTER. Then, choose a task from the list, and it will run.

When first opening the workspace, a notification will appear in VS Code asking you to download recommended extensions, adding Astro language support, comment categorisation and enhanced Git control to name a few. We recommend that you download theese extensions when asked, as they will help massively with coding for the website.

We are using pnpm for package management, as it is fast and space-efficient. This, of course, requires you to have both Node.js and pnpm installed - if you don't, none of this will work. Download Node and pnpm.

When making any changes to the new website, ensure to use the pre Git branch and open a Pull Request between the two branches. This is done to ensure that the production deployment doesn't become incomplete and/or buggy.

For code consistency, we recommend formatting the files with Prettier using the VS Code task or pnpm prettier . --write.

Commands

Command Action
pnpm i Installs dependencies
pnpm run dev Starts a dev server at localhost:4321 (VS Code task available)
pnpm run astro ... Run CLI commands like astro add, astro check
pnpm run astro -- --help Get help using the Astro CLI
pnpm prettier . --write Format with Prettier (VS Code task available)

If you need any help with Astro, check out their documentation.