Overview:
This product analysis is about a starter template for the Astro project. The template includes features such as Astro v2 with disabled Astro Telemetry, Astro Compress to compress output HTML, CSS, JS, and images, Astro PurgeCSS to remove unused CSS from build output, automation of releasing new versions using GitHub Actions and following the git-flow branching model, automation of Netlify deployment with support for GitHub deploy environment, automation of rebasing PR branch via PR comment, and various development features like PNPM, Conventional commit, ESLint, Prettier, Renovate, Vitest, changie, git-chglog, and taskfile. The installation process involves setting up a GitHub repository, creating a Netlify site, and adding necessary repository secrets. The project structure includes folders and files for organizing Astro project files.
Features:
- Astro v2 with disabled Astro Telemetry
- Astro Compress - Compress output HTML, CSS, JS, and images.
- Astro PurgeCSS - Remove unused CSS from build output.
- Automate releasing new versions using GitHub Actions and following the git-flow branching model
- Automate Netlify deployment with support for GitHub deploy environment
- Automate rebasing PR branch via PR comment: /rebase, /autosquash, /rebase-autosquash
- Development features - Node package manager: PNPM, Conventional commit, ESLint, Prettier, Renovate, Vitest, changie, git-chglog, and taskfile.
Installation:
To install the Astro starter template and set up a new project, follow these steps:
- Create a new GitHub Repository.
- Create a new Netlify site. It is recommended to deploy manually and disable the Branch deploy and Deploy Preview features.
- Go to https://github.com/{user}/{repository}/settings/secrets/actions/new and add the following repository secrets:
- GH_TOKEN: GitHub Personal Access Token with repo scope.
- NETLIFY_AUTH_TOKEN: Netlify Authentication Token.
- NETLIFY_SITE_ID: Netlify site ID.
Project Structure: Inside your Astro project, you will find the following folders and files:
- The
.astroor.mdfiles in thesrc/pages/directory are treated as routes based on their file names. - There are no special requirements for the
src/components/directory. - Other folders like
public/,src/styles/, andsrc/layouts/can be used for organizing project files.
Summary:
The Astro starter template provides a convenient setup for the Astro project with several useful features like automation, compression, and code analysis tools. It also includes a guide for installation and organizes project files in a structured manner.