From 6cde0f1ca0d947a1449a3b0f8ff933464138463d Mon Sep 17 00:00:00 2001 From: Jamie Nguyen Date: Wed, 4 Feb 2026 11:47:34 +0000 Subject: [PATCH] Improve package.json with extra fields Add "repository" which is required for Trusted Publishing, but also useful for having a link to the repository on npmjs.com. Add "files" (replacing .npmignore) which will remove these from our published tarball: - .github/ - .prettierrc - example/ - src/ - test/ - tsconfig.json Add "publishConfig" to be explicit, and prevents problems if we forget `--access public` in CI. --- .npmignore | 5 ----- package.json | 14 ++++++++++++++ 2 files changed, 14 insertions(+), 5 deletions(-) delete mode 100644 .npmignore diff --git a/.npmignore b/.npmignore deleted file mode 100644 index c40f846..0000000 --- a/.npmignore +++ /dev/null @@ -1,5 +0,0 @@ -api-extractor.json -scripts/ -build/ -temp/ -etc/ \ No newline at end of file diff --git a/package.json b/package.json index 5629b78..3365012 100644 --- a/package.json +++ b/package.json @@ -17,6 +17,20 @@ }, "author": "Friendly Captcha GmbH", "license": "MIT", + "repository": { + "type": "git", + "url": "https://github.com/FriendlyCaptcha/friendly-captcha-javascript" + }, + "files": [ + "dist", + "LICENSE", + "README.md", + "CHANGELOG.md" + ], + "publishConfig": { + "access": "public", + "registry": "https://registry.npmjs.org/" + }, "devDependencies": { "@ava/typescript": "^3.0.1", "@babel/cli": "^7.19.3",