Skip to content

Commit d7947ed

Browse files
committed
Pin dep versions in templates.
1 parent a172ccf commit d7947ed

2 files changed

Lines changed: 24 additions & 4 deletions

File tree

‎docs/template-scaffolding.md‎

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,26 @@ version using plain `major.minor.patch`, such as `yarn@4.18.1`.
6666
CLI installation, retry instructions, and next-step commands follow
6767
this choice. The starter uses Yarn with the `node-modules` linker, Vitest app
6868
tests outside `content/`, and a standalone `biome.json`.
69+
70+
Pin the starter's third-party development tools (`@biomejs/biome`, `@types/node`,
71+
`vite`, and `vitest`) to exact versions validated by template verification.
72+
Template verification installs a fresh project without the repository lockfile,
73+
so ranges can silently select newer tools. The repository root can keep its
74+
dependency ranges: its committed lockfile and CI checks control upgrades there.
75+
Upgrade template tools deliberately when needed, rather than for every release:
76+
update the template manifest, review the resulting changes, and run
77+
`yarn verify-templates` against freshly bundled packages before merging. These
78+
direct pins do not freeze transitive dependencies; preserve the generated
79+
project's lockfile for repeatable installs. PureStack dependencies continue to
80+
use `latest` as described above.
81+
82+
For Biome, keep the template's `biome.json` schema URL aligned with its pinned CLI
83+
version and migrate that configuration with the selected CLI
84+
(`biome migrate --write`) during upgrades. Manage the root configuration against
85+
the repository's locked CLI version. Even patch releases can change formatting
86+
or lint results;
87+
[Biome recommends exact version pins](https://biomejs.dev/internals/versioning/).
88+
6989
For Yarn projects without a template-supplied lockfile, the CLI creates an empty
7090
`yarn.lock` before installation to establish a separate project inside parent
7191
workspaces. Existing template lockfiles are preserved.

‎templates/starter/template/package.json‎

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -23,10 +23,10 @@
2323
"regor": "latest"
2424
},
2525
"devDependencies": {
26-
"@types/node": "^26.6.5",
27-
"@biomejs/biome": "^2.6.2",
26+
"@types/node": "26.6.5",
27+
"@biomejs/biome": "2.6.2",
2828
"@purestack/ts-minidom": "latest",
29-
"vite": "^8.3.5",
30-
"vitest": "^5.0.5"
29+
"vite": "8.3.5",
30+
"vitest": "5.0.3"
3131
}
3232
}

0 commit comments

Comments
 (0)