From 9a10f3d9c3ed8c9adcffa6f3943e079e4c8ee00d Mon Sep 17 00:00:00 2001 From: Anthony Lukach Date: Mon, 25 May 2026 09:00:19 -0700 Subject: [PATCH 1/3] chore: scope npm publish to dist/ and rebuild before publish Add a `files` allowlist limiting the published tarball to `dist/` (plus npm-default README/LICENSE/package.json), and a `prepublishOnly` script that wipes `dist/` and rebuilds. Without these, the tarball included all of `src/` (tests, configs) and any stale outputs left in `dist/`. With them, `npm pack --dry-run` drops from 107 files / 1.1MB unpacked to 26 files / 126KB unpacked. Co-Authored-By: Claude Opus 4.7 (1M context) --- package.json | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/package.json b/package.json index c3d8826..62b2b68 100644 --- a/package.json +++ b/package.json @@ -53,7 +53,11 @@ "scripts": { "lint": "eslint .", "test": "jest", - "build": "tsc -b && vite build" + "build": "tsc -b && vite build", + "prepublishOnly": "rm -rf dist && yarn build" }, + "files": [ + "dist" + ], "packageManager": "yarn@4.10.3" } From 9362b07f9c1b02bc00e454de3c32e2202852a747 Mon Sep 17 00:00:00 2001 From: Anthony Lukach Date: Mon, 25 May 2026 09:02:04 -0700 Subject: [PATCH 2/3] chore: drop .npmignore now that files allowlist is set With `files: ["dist"]` in package.json, npm uses the allowlist and ignores `.npmignore`. Removing the now-inert file to avoid confusion. Co-Authored-By: Claude Opus 4.7 (1M context) --- .npmignore | 3 --- 1 file changed, 3 deletions(-) delete mode 100644 .npmignore diff --git a/.npmignore b/.npmignore deleted file mode 100644 index fb2d594..0000000 --- a/.npmignore +++ /dev/null @@ -1,3 +0,0 @@ -example -node_modules -.github From 7434a320fbd3041a642d9a922012ea0aa9a36665 Mon Sep 17 00:00:00 2001 From: Anthony Lukach Date: Mon, 25 May 2026 09:21:30 -0700 Subject: [PATCH 3/3] 1.0.0-alpha.3 Co-Authored-By: Claude Opus 4.7 (1M context) --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 62b2b68..67ff056 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@developmentseed/stac-react", - "version": "1.0.0-alpha.2", + "version": "1.0.0-alpha.3", "description": "React components and hooks for building STAC-API front-ends", "repository": "git@github.com:developmentseed/stac-react.git", "authors": [