Skip to content

Commit d937f80

Browse files
authored
feat(legacy-charts): add typescript definitions for legacy charts (#839)
add typescript definitions for legacy charts #825
1 parent 6f8fa51 commit d937f80

File tree

4 files changed

+7
-6
lines changed

4 files changed

+7
-6
lines changed

.eslintignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,3 @@
11
dist/*
22
node_modules/*
3+
legacy/index*

.gitignore

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,4 @@ npm-debug.log*
1616
coverage
1717

1818
# legacy builds
19-
/legacy/index.cjs
20-
/legacy/index.cjs.map
21-
/legacy/index.js
22-
/legacy/index.js.map
19+
/legacy/index*

legacy/package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,8 @@
55
"module": "./legacy/index.js"
66
},
77
"scripts": {
8-
"unit": "jest -c jest.config.json"
8+
"unit": "jest -c jest.config.json",
9+
"emitDeclarations": "tsc index.js --allowJs --skipLibCheck --declaration --emitDeclarationOnly --declarationMap"
910
},
1011
"devDependencies": {
1112
"@babel/core": "7.17.9",

package.json

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,9 @@
5252
"scripts": {
5353
"prepublishOnly": "pnpm test && pnpm build && del ./package && clean-publish",
5454
"postpublish": "del ./package",
55-
"emitDeclarations": "tsc --emitDeclarationOnly",
55+
"emitDeclarations:legacy": "cd legacy && pnpm emitDeclarations",
56+
"emitDeclarations:base": "tsc --emitDeclarationOnly",
57+
"emitDeclarations": "pnpm emitDeclarations:base && pnpm emitDeclarations:legacy",
5658
"build": "rollup -c & pnpm emitDeclarations",
5759
"unit": "pnpm unit:base && pnpm unit:legacy",
5860
"unit:base": "jest -c jest.config.json",

0 commit comments

Comments
 (0)