Skip to content

Commit ca60b12

Browse files
fix: resolve Vuepress1 and Vuepress2 declare file conflict
1 parent ff9ad94 commit ca60b12

File tree

7 files changed

+121
-15
lines changed

7 files changed

+121
-15
lines changed

β€Žpackage.jsonβ€Ž

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@
2222
"coverage": "vitest run --coverage",
2323
"preinstall": "npx only-allow pnpm",
2424
"lint:fix": "eslint . --fix",
25+
"typecheck": "tsc --noEmit",
2526
"lint": "eslint .",
2627
"test": "vitest"
2728
},

β€Žpackages/vuepress-plugin-export-pdf-v2/package.jsonβ€Ž

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,10 +22,19 @@
2222
"types": "dist/index.d.ts",
2323
"exports": {
2424
".": {
25+
"types": "./dist/index.d.ts",
2526
"require": "./dist/index.cjs",
2627
"import": "./dist/index.mjs"
2728
}
2829
},
30+
"typesVersions": {
31+
"*": {
32+
"*": [
33+
"./dist/*",
34+
"./dist/index.d.ts"
35+
]
36+
}
37+
},
2938
"files": [
3039
"bin",
3140
"dist"
@@ -35,6 +44,7 @@
3544
},
3645
"scripts": {
3746
"build": "unbuild",
47+
"prepublishOnly": "nr build",
3848
"dev": "esno ./src/commands/press-export-pdf.ts export ./example/vuepress-next/docs"
3949
},
4050
"bugs": {

β€Žpackages/vuepress-plugin-export-pdf/package.jsonβ€Ž

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,17 @@
1919
"main": "dist/index.cjs",
2020
"module": "dist/index.mjs",
2121
"types": "dist/index.d.ts",
22+
"typesVersions": {
23+
"*": {
24+
"*": [
25+
"./dist/*",
26+
"./dist/index.d.ts"
27+
]
28+
}
29+
},
2230
"exports": {
2331
".": {
32+
"types": "./dist/index.d.ts",
2433
"require": "./dist/index.cjs",
2534
"import": "./dist/index.mjs"
2635
}
@@ -34,6 +43,7 @@
3443
},
3544
"scripts": {
3645
"build": "unbuild",
46+
"prepublishOnly": "nr build",
3747
"dev": "esno ./src/commands/press-export-pdf.ts export ./example/vue-press/docs"
3848
},
3949
"bugs": {
@@ -63,7 +73,7 @@
6373
"semver": "^7.3.7"
6474
},
6575
"devDependencies": {
66-
"@condorhero/vuepress-types": "workspace:^",
76+
"@condorhero/vuepress-types": "^2.0.0",
6777
"@types/cli-progress": "^3.11.0",
6878
"@types/debug": "^4.1.7",
6979
"@types/envinfo": "^7.8.1",

β€Žpackages/vuepress-plugin-export-pdf/src/types.d.tsβ€Ž

Lines changed: 0 additions & 3 deletions
This file was deleted.
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
2+
{
3+
"extends": "../../tsconfig.json",
4+
"compilerOptions": {
5+
"baseUrl": ".",
6+
"paths": {
7+
"vuepress": ["./node_modules/@condorhero/vuepress-types"]
8+
}
9+
}
10+
}

β€Žpackages/vuepress-types/package.jsonβ€Ž

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@condorhero/vuepress-types",
3-
"version": "2.0.0",
3+
"private": true,
44
"description": "VuePress TypeScript helpers for 1.x",
55
"keywords": [
66
"types",

β€Žpnpm-lock.yamlβ€Ž

Lines changed: 88 additions & 10 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
Β (0)