From 8e026c9028655a1dd31c50f999c0dce137430c6e Mon Sep 17 00:00:00 2001 From: Andre Staltz Date: Sun, 25 Jun 2023 11:42:13 +0300 Subject: [PATCH] build .d.ts files --- .gitignore | 1 + package.json | 2 +- tsconfig.json | 3 ++- 3 files changed, 4 insertions(+), 2 deletions(-) diff --git a/.gitignore b/.gitignore index 44bcc03..ac659d1 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,4 @@ +lib/**/*.d.ts node_modules .nyc_output coverage diff --git a/package.json b/package.json index 18c5b43..f1c0139 100644 --- a/package.json +++ b/package.json @@ -38,7 +38,7 @@ "typescript": "^5.0.2" }, "scripts": { - "build": "tsc", + "build": "rm lib/**/*.d.ts && tsc", "test": "node --test", "format-code": "prettier --write \"*.js\" \"(test|lib)/*.js\"", "format-code-staged": "pretty-quick --staged --pattern \"*.js\" --pattern \"(test|lib)/*.js\"", diff --git a/tsconfig.json b/tsconfig.json index f6eb639..ae7ca1a 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -3,7 +3,8 @@ "exclude": ["coverage/", "node_modules/", "test/"], "compilerOptions": { "checkJs": true, - "noEmit": true, + "declaration": true, + "emitDeclarationOnly": true, "exactOptionalPropertyTypes": true, "forceConsistentCasingInFileNames": true, "lib": ["es2021", "dom"],