Skip to content

Commit

Permalink
[WIP] Add TypeScript declaration files to output
Browse files Browse the repository at this point in the history
Closes #150
  • Loading branch information
EdricChan03 committed Jul 17, 2023
1 parent 4b0fc62 commit a39e762
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 2 deletions.
7 changes: 6 additions & 1 deletion bili.config.base.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,14 @@ import type { Config } from "bili";
const config: Config = {
plugins: {
typescript2: {
useTsconfigDeclarationDir: true,
tsconfigOverride: {
include: ["src"],
exclude: ["**/*.test.ts"]
exclude: ["**/*.test.ts"],
compilerOptions: {
declaration: true,
declarationDir: "./dist/types"
}
}
}
},
Expand Down
7 changes: 6 additions & 1 deletion bili.config.community.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,14 @@ import type { Config } from "bili";
const config: Config = {
plugins: {
typescript2: {
useTsconfigDeclarationDir: true,
tsconfigOverride: {
include: ["src"],
exclude: ["**/*.test.ts"]
exclude: ["**/*.test.ts"],
compilerOptions: {
declaration: true,
declarationDir: "./dist/types"
}
}
}
},
Expand Down
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
"module": "dist/ad-notations.esm.js",
"unpkg": "dist/ad-notations.umd.js",
"jsdelivr": "dist/ad-notations.umd.js",
"types": "dist/types/index.d.ts",
"keywords": [
"notations",
"numbers"
Expand Down

0 comments on commit a39e762

Please sign in to comment.