Skip to content

Commit 69a0cc8

Browse files
Upgrade to pnpm 10.33.0 (#17)
1 parent 692bd3c commit 69a0cc8

File tree

6 files changed

+75
-53
lines changed

6 files changed

+75
-53
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"private": true,
33
"type": "module",
4-
"packageManager": "pnpm@10.13.1",
4+
"packageManager": "pnpm@10.33.0",
55
"engines": {
66
"node": "^20.19.0 || >=22.12.0"
77
},

packages/create-vue-lib/src/template/base/config/package.json.ejs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"private": true,
33
"type": "module",
4-
"packageManager": "pnpm@10.13.1",
4+
"packageManager": "pnpm@10.33.0",
55
"engines": {
66
"node": "^20.19.0 || >=22.12.0"
77
},

packages/create-vue-lib/src/template/base/config/pnpm-workspace.yaml.ejs

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -11,11 +11,13 @@ packages:
1111
<%_ } _%>
1212
<%_ } _%>
1313

14-
ignoredBuiltDependencies:
15-
- simple-git-hooks
14+
minimumReleaseAge: 1440
1615

17-
onlyBuiltDependencies:
16+
allowBuilds:
1817
<%_ if (config.includeTailwind) { _%>
19-
- '@tailwindcss/oxide'
18+
'@tailwindcss/oxide': true
2019
<%_ } _%>
21-
- esbuild
20+
'esbuild': true
21+
'simple-git-hooks': false
22+
23+
dedupePeers: true

packages/docs/src/why.md

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,13 +12,13 @@ But applications and libraries need different things.
1212

1313
Libraries such as [Vue core](https://github.com/vuejs/core), [Vue Router](https://github.com/vuejs/router) and [Pinia](https://github.com/vuejs/pinia/) have also heavily influenced the project structure used by this tool, especially the use of a `packages` directory and pnpm workspaces. Various other tools, such as `simple-git-hooks`, `lint-staged` and VitePress, have been chosen to align with those projects.
1414

15-
Those projects use [rollup](https://rollupjs.org/) directly for their builds, rather than Vite. Vite already uses rollup behind the scenes, but using it directly is more flexible. Using Vite as a wrapper has a few advantages:
15+
Those projects use [rolldown](https://rolldown.rs/) directly for their builds, rather than Vite. Vite already uses rolldown behind the scenes, but using it directly is more flexible. Using Vite as a wrapper has a few advantages:
1616

1717
- Vite is familiar to most members of the Vue community.
1818
- Using Vite keeps us closer to `create-vue`.
1919
- Vite has its own ecosystem of useful plugins.
2020

21-
In particular, the libraries mentioned above don't use `.vue` files in their source code. Compiling `.vue` files with rollup is certainly possible, but it's more convenient to reuse the same toolchain used to build Vue applications.
21+
In particular, the libraries mentioned above don't use `.vue` files in their source code. Compiling `.vue` files with rolldown is certainly possible, but it's more convenient to reuse the same toolchain used to build Vue applications.
2222

2323
## Multiple packages
2424

@@ -60,7 +60,9 @@ We use a `postinstall` target in `scripts` to update the git hooks, ensuring the
6060

6161
## `pnpm-workspace.yaml`
6262

63-
Since version 10, pnpm no longer runs `postinstall` scripts in the packages it installs, instead showing a warning. To avoid the warning, these need to be explicitly enabled or disabled in `pnpm-workspace.yaml`, using `onlyBuiltDependencies` or `ignoredBuiltDependencies` respectively.
63+
### `allowBuilds`
64+
65+
Since version 10, pnpm no longer runs `postinstall` scripts in the packages it installs, instead showing a warning. To avoid the warning, these need to be explicitly enabled or disabled via the [`allowBuilds`](https://pnpm.io/settings#allowbuilds) setting in `pnpm-workspace.yaml`.
6466

6567
There are 3 packages where this is currently relevant:
6668

@@ -72,6 +74,10 @@ Both `esbuild` and `@tailwindcss/oxide` have platform-specific binaries that are
7274

7375
It should be safe to disable all of these `postinstall` scripts in `pnpm-workspace.yaml` if you prefer.
7476

77+
### `minimumReleaseAge`
78+
79+
Setting [`minimumReleaseAge`](https://pnpm.io/settings#minimumreleaseage) to `1440` prevents pnpm from installing any packages published in the last 24 hours. This helps to protect against supply chain attacks, as malicious versions of popular packages are typically removed from the npm registry within a few hours.
80+
7581
## `.gitignore`
7682

7783
The `.gitignore` is similar to `create-vue`.

pnpm-lock.yaml

Lines changed: 51 additions & 39 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)