From ef9bc55a19cebb5e429b730db69c8c874e6444a6 Mon Sep 17 00:00:00 2001 From: Matt Vickers Date: Wed, 8 Nov 2023 13:46:37 -0600 Subject: [PATCH 1/2] Add exports to package.json --- package.json | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/package.json b/package.json index 64fe813d3..3c4568b1a 100644 --- a/package.json +++ b/package.json @@ -17,6 +17,21 @@ ] } }, + "exports": { + ".": { + "types": "./build/ts/index.d.ts", + "module": "./build/esm/index.js", + "import": "./build/esm/index.js", + "default": "./build/cjs/index.js" + }, + "./PolarisVizProvider": { + "types": "./build/ts/index.d.ts", + "module": "./build/esm/components/PolarisVizProvider/PolarisVizProvider.js", + "import": "./build/esm/components/PolarisVizProvider/PolarisVizProvider.js", + "default": "./build/cjs/components/PolarisVizProvider/PolarisVizProvider.js" + }, + "./*": "./*" + }, "scripts": { "build": "loom build", "storybook": "STORYBOOK_SHOW=dev start-storybook -p 6006 -s public", From d59525c6b85a3b47abac99aa58becfced9a574c2 Mon Sep 17 00:00:00 2001 From: Matt Vickers Date: Wed, 8 Nov 2023 13:59:51 -0600 Subject: [PATCH 2/2] Apply suggestions from code review Co-authored-by: Jason Miller --- package.json | 2 ++ 1 file changed, 2 insertions(+) diff --git a/package.json b/package.json index 3c4568b1a..3191a41f5 100644 --- a/package.json +++ b/package.json @@ -20,12 +20,14 @@ "exports": { ".": { "types": "./build/ts/index.d.ts", + "esnext": "./build/esm/index.esnext", "module": "./build/esm/index.js", "import": "./build/esm/index.js", "default": "./build/cjs/index.js" }, "./PolarisVizProvider": { "types": "./build/ts/index.d.ts", + "esnext": "./build/esm/components/PolarisVizProvider/PolarisVizProvider.esnext", "module": "./build/esm/components/PolarisVizProvider/PolarisVizProvider.js", "import": "./build/esm/components/PolarisVizProvider/PolarisVizProvider.js", "default": "./build/cjs/components/PolarisVizProvider/PolarisVizProvider.js"