From 593ef1b2e825993955dc089c3cf7a734ecbcef56 Mon Sep 17 00:00:00 2001 From: Astrian Zheng Date: Tue, 25 Feb 2025 10:18:57 +1100 Subject: [PATCH] feat: update package.json and tsconfig.app.json to correct type definitions and enable declaration file generation --- package.json | 4 ++-- tsconfig.app.json | 4 +++- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/package.json b/package.json index 7b5046a..1ecb6b9 100644 --- a/package.json +++ b/package.json @@ -22,14 +22,14 @@ "vue-tsc": "^2.2.0" }, "exports": { - "types": "./dist_types/src/index.js", + "types": "./dist_types/src/index.d.ts", "import": "./dist/datenel-vue3.js", "require": "./dist/datenel-vue3.umd.cjs", "default": "./dist/datenel-vue3.umd.cjs" }, "main": "dist/datenel-vue3.umd.cjs", "module": "dist/datenel-vue3.js", - "types": "dist_types/src/index.js", + "types": "dist_types/src/index.d.ts", "files": [ "dist", "dist_types" diff --git a/tsconfig.app.json b/tsconfig.app.json index df2685c..d27b36e 100644 --- a/tsconfig.app.json +++ b/tsconfig.app.json @@ -13,7 +13,9 @@ "resolveJsonModule": true, "esModuleInterop": true, "lib": ["esnext", "DOM", "dom.iterable", "scripthost"], - "skipLibCheck": true + "skipLibCheck": true, + "declaration": true, + "emitDeclarationOnly": true, }, "include": ["src/**/*.ts", "src/**/*.d.ts", "src/**/*.tsx", "src/**/*.vue", "playground/**/*.ts", "playground/**/*.d.ts", "playground/**/*.tsx", "playground/**/*.vue"] } \ No newline at end of file