From 7bbc52a963d89c36a905d8c2bb4ebec30c0ae8ba Mon Sep 17 00:00:00 2001 From: Oliver Eyton-Williams Date: Fri, 26 Apr 2024 00:43:07 +0200 Subject: [PATCH] build: support modern node resolution (#172) If tsconfig's moduleResolution is set to Node16 or NodeNext it stops using the "types" property in package.json and, instead, relies on "types" inside "exports". This now supports both. --- package.json | 1 + 1 file changed, 1 insertion(+) diff --git a/package.json b/package.json index 6e2de1e..fc6d022 100644 --- a/package.json +++ b/package.json @@ -13,6 +13,7 @@ ], "exports": { ".": { + "types": "./dist/index.d.ts", "require": "./dist/index.cjs", "default": "./dist/index.mjs" }