Commit 9fbf53d
chore: untrack auto-generated MSW worker and relax engines.node (#2714)
* chore: gitignore auto-generated mockServiceWorker.js
MSW postinstall auto-syncs public/mockServiceWorker.js via
package.json "msw.workerDirectory", so the update-msw.yml workflow
is redundant. Ignore the generated file and remove the workflow.
Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
* chore: add msw init to prepare script
pnpm hardlinks msw from its global store after the first build, so
msw's postinstall doesn't re-run on subsequent installs — new clones
hitting a warm store would not get public/mockServiceWorker.js.
Run `msw init public --save` in the prepare script so every
`pnpm install` regenerates the worker deterministically.
Normalize workerDirectory to "public" to keep `--save` idempotent
(passing "./public" triggers msw to append both forms).
Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
* chore: use postinstall instead of prepare for msw init
postinstall runs on every install variant (including `pnpm add`),
while prepare can skip under `--production` or single-package adds.
postinstall also avoids a future conflict with tools that claim
prepare (e.g., Husky).
Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
* fix
* fix
---------
Co-authored-by: Claude Opus 4.7 (1M context) <[email protected]>1 parent 7bd0967 commit 9fbf53d
5 files changed
Lines changed: 5 additions & 396 deletions
File tree
- .claude/rules
- .github/workflows
- public
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
10 | | - | |
11 | 10 | | |
12 | 11 | | |
13 | 12 | | |
This file was deleted.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
236 | 236 | | |
237 | 237 | | |
238 | 238 | | |
| 239 | + | |
| 240 | + | |
| 241 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
89 | 89 | | |
90 | 90 | | |
91 | 91 | | |
92 | | - | |
| 92 | + | |
93 | 93 | | |
94 | 94 | | |
95 | 95 | | |
| |||
105 | 105 | | |
106 | 106 | | |
107 | 107 | | |
108 | | - | |
| 108 | + | |
109 | 109 | | |
110 | 110 | | |
0 commit comments