From ad4df6db1247d786af6198d8aae08dcc2308041d Mon Sep 17 00:00:00 2001 From: Sean Collings Date: Thu, 12 Dec 2024 18:42:19 -0700 Subject: [PATCH] fixes for vite / vitest builds --- packages/atomic-elements/.npmignore | 1 - packages/atomic-elements/package.json | 6 ++++++ packages/hooks/package.json | 7 +++++-- packages/hooks/tsconfig.build.json | 3 ++- 4 files changed, 13 insertions(+), 4 deletions(-) diff --git a/packages/atomic-elements/.npmignore b/packages/atomic-elements/.npmignore index 1ffc2b08..170332c6 100644 --- a/packages/atomic-elements/.npmignore +++ b/packages/atomic-elements/.npmignore @@ -6,4 +6,3 @@ bin docs node_modules public -src diff --git a/packages/atomic-elements/package.json b/packages/atomic-elements/package.json index 4f48aebe..8a26f6ad 100644 --- a/packages/atomic-elements/package.json +++ b/packages/atomic-elements/package.json @@ -9,6 +9,12 @@ "files": [ "dist" ], + "exports": { + "import": "./dist/esm/index.js", + "require": "./dist/cjs/index.js", + "default": "./dist/esm/index.js", + "types": "./dist/types/index.d.ts" + }, "license": "MIT", "dependencies": { "@internationalized/date": "^3.5.2", diff --git a/packages/hooks/package.json b/packages/hooks/package.json index 7e6faa8c..59e8dc96 100644 --- a/packages/hooks/package.json +++ b/packages/hooks/package.json @@ -1,12 +1,15 @@ { "name": "@atomicjolt/hooks", - "version": "0.2.0", + "version": "0.3.2", "author": "Sean Collings ", "license": "MIT", + "main": "dist/index.js", "module": "dist/index.js", + "type": "module", "types": "dist/types/index.d.ts", "files": [ - "dist/**/*" + "dist", + "src" ], "peerDependencies": { "react": "^16.0.0 || ^17.0.0 || ^18.0.0" diff --git a/packages/hooks/tsconfig.build.json b/packages/hooks/tsconfig.build.json index 7ea87ae5..baa08287 100644 --- a/packages/hooks/tsconfig.build.json +++ b/packages/hooks/tsconfig.build.json @@ -3,6 +3,7 @@ "include": ["src/index.ts"], "compilerOptions": { "outDir": "./dist", - "declarationDir": "./dist/types" + "declarationDir": "./dist/types", + "module": "ESNext" } }