From 3320d2e923be021f4d07b94f88ab571792aaca3b Mon Sep 17 00:00:00 2001 From: trim21 Date: Sun, 19 Jul 2026 03:21:40 +0800 Subject: [PATCH] fix: correct exports field to use subpath "." with import condition The previous object form {"import": "./index.js"} treated "import" as a subpath (bencode/import) rather than a condition, leaving the package root entry point undefined. Wrapping it inside "." makes "import" a proper condition on the root export. --- package.json | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/package.json b/package.json index 4909cb4..faf1cd0 100644 --- a/package.json +++ b/package.json @@ -44,7 +44,9 @@ "node": ">=12.20.0" }, "exports": { - "import": "./index.js" + ".": { + "import": "./index.js" + } }, "repository": { "type": "git",