From b0009a0e629779c94971c996cb45b6e889ce0729 Mon Sep 17 00:00:00 2001 From: Steve Larson <9larsons@gmail.com> Date: Mon, 29 Jun 2026 13:03:51 -0500 Subject: [PATCH] Removed @tryghost/parse-email-address from pnpm dev fan-out MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit parse-email-address is a 20-line workspace package wrapping the npm parse-email-address module. Its dev script ran tsc --watch continuously (~145 MB RSS, plus another ~145 MB of Nx run-executor + pnpm wrapper overhead) to emit build/index.js + build/index.d.ts. ghost/core runs with node --conditions=source --import=tsx (see ghost/core/nodemon.json), so its runtime imports resolve through the source export condition and load src/index.ts directly via tsx — build/ is never read at runtime. But ghost/core type-checks against the package types field, which points at build/index.d.ts, so a fresh clone with no build/ would break editor type resolution. Added a prepare script to parse-email-address so pnpm install builds build/ once. tsconfig.tsbuildinfo and build/ are both gitignored, so a true fresh clone always triggers the build. Source edits to this package require a manual rebuild (or pnpm --filter @tryghost/parse-email-address dev) — acceptable for a tiny rarely-touched package. Net savings: 1 host process and ~290 MB RSS per dev session. no ref --- ghost/parse-email-address/package.json | 1 + package.json | 3 +-- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/ghost/parse-email-address/package.json b/ghost/parse-email-address/package.json index 6efba7d12be..e15c0075199 100644 --- a/ghost/parse-email-address/package.json +++ b/ghost/parse-email-address/package.json @@ -18,6 +18,7 @@ "dev": "tsc --watch --preserveWatchOutput --sourceMap", "build": "pnpm build:tsc", "build:tsc": "tsc", + "prepare": "pnpm build", "test:unit": "NODE_ENV=testing vitest run --coverage", "test": "pnpm test:types && pnpm test:unit", "test:types": "tsc --noEmit", diff --git a/package.json b/package.json index 8c62900d2b8..b923cb7c981 100644 --- a/package.json +++ b/package.json @@ -150,8 +150,7 @@ "@tryghost/signup-form", "@tryghost/sodo-search", "@tryghost/announcement-bar", - "@tryghost/admin-toolbar", - "@tryghost/parse-email-address" + "@tryghost/admin-toolbar" ] } ]