Skip to content

site

Sites built to a folder: the build, broken links, page weight, and the sitemap. It requires html.

Check Stage Level What it does
site/build push recommended Runs site.build_command, and fails on an error or a missing output folder.
site/html-validate push recommended Validates every built page with html-validate.
site/purgecss push recommended Finds selectors in the built stylesheets that no page or script uses.
site/linkinator push recommended Serves the built site and follows every link between its pages, stylesheets, and fragments.
site/size push recommended Sums the compressed weight of the built paths each ceiling in site.size_limit names.
site/sitemap push recommended Compares the sitemap with the built pages, and reports a listed route with no page or a page left out.
site/unused-assets push all Finds files under an assets folder that no page, stylesheet, or script names.
Setting What it sets
site.build_command The command that builds the site. Without it, gspot runs the build script of the package manager.
site.build_folder The folder the build writes.
site.allowed_unlisted_pages Built pages the sitemap leaves out on purpose.
site.size_limit Size limits: the built paths, and the most kilobytes they may weigh compressed.
tools.purgecss.safelist Class names a script adds at run time: the names and the reason.

gspot selects it in a scope with file paths site.webmanifest, sitemap.xml.

Rule file Installed when
.gspot/configurations/framework/site/rules/SITE.md Always
Tool Version
linkinator 8.1.0
purgecss 7.0.2

gspot writes .gspot/configurations/framework/site/html-validate.json and .gspot/configurations/framework/site/purgecss.mjs.