Repository navigation
Clean up the site: lighter first load, simpler checks - #2
Merged
Merged
Conversation
The tests served a copy in _site that only npm run check refreshed, so npm test could pass on stale files and failed on a fresh clone. Everything in site/ is now what gets tested and published.
html-validate 11 needs ^22.22.0 or >=24.8.0, so >=22.13 had gone stale.
The pages use 43 characters, but the fonts carried 202 plus hinting. Together they go from 27.2 KB to 9.9 KB. Text is pixel-identical in Chrome on macOS, which ignores hinting. The existing test flags any character outside the set.
The same 401 points, in 1.4 KB less of index.html. og.png differs in 10 anti-aliased pixels, from rounding as Chrome adds up relative coordinates.
fontkit brought in 11 of the 29 packages for one test. The range matches the command that cuts the fonts.
The dark colors move into the SVG, which also gives the favicon a dark version. Both pages render pixel-identically in light and dark.
One hover rule for every link, which also gives the 404 page's links a hover color. One color-scheme for both themes. Phone spacing is now the default, so the 640px block goes and screens from 641 to 699px get the phone spacing. Drop the default font-style lines.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
A cleanup round before new work: less tooling, a lighter first load, and one test gap closed. Each change is its own commit, so they can be reviewed one at a time.
What changed
Fixes
site/directly. The tests served a copy in_sitethat onlynpm run checkrefreshed, sonpm testcould pass on stale files: with the stylesheet link broken, it still passed 24 of 24. On a fresh clone it waited 60 seconds and then failed. The published files now live insite/, which removescollect-site.sh, thecollectscript and_site.enginessaid>=22.13, but html-validate 11 needs^22.22.0 || >=24.8.0.Performance
index.html.Removals and duplication
.nojekyll. Actions deployments never read it, and it wasn't being published.fontkit. It brought in 11 of 29 packages for one test, which now uses a character range.favicon.svginstead of keeping three copies. The dark colors move into the SVG, so the favicon gets a dark version too.color-scheme, and one breakpoint fewer.Results
Load times are medians of 9 cold loads on a throttled local server, so the comparison matters more than the exact numbers. A fast desktop connection shows no meaningful change.
How it was checked
npm run checkpasses all 24 tests on Node 22.23, andnpm testworks from a clean export of the branch with no other step.mainin Chrome on macOS, 44 of 52 size, theme and page combinations are pixel-identical. The other 8 are the 641px and 699px screens on both pages, which is the intended spacing change below.What to look at
/LICENSEis no longer published on the site. No page linked to it, and it stays in the repository.og.pngdiffers in 10 of 756,000 pixels, from rounding on the edge of the signal line.After merging
_sitefolder from any existing checkout. It's no longer ignored, so it will show up as untracked.--directory site, as the README says.