vitepress-linkcard 2.0.1 → 2.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +11 -13
- package/dist/.cjs.min.js +1 -1
- package/dist/.esm.min.js +1 -1
- package/package.json +47 -54
package/README.md
CHANGED
|
@@ -9,13 +9,11 @@ vitepress-linkcard
|
|
|
9
9
|
You can see: [A blog generated with this plugin](https://asumoranda.com/posts/10-vitepress-linkcard.html) | [Docs by TypeDoc](https://asumo-1xts.github.io/vitepress-linkcard/)
|
|
10
10
|
|
|
11
11
|
[](https://www.npmjs.com/package/vitepress-linkcard)
|
|
12
|
-
[](https://www.npmjs.com/package/vitepress-linkcard)
|
|
13
12
|
[](https://vuejs.github.io/vitepress/v1]/)
|
|
14
13
|
[](/LICENSE)
|
|
15
14
|
|
|
16
15
|
[](https://yarnpkg.com/)
|
|
17
|
-
[](https://github.com/asumo-1xts/vitepress-linkcard/actions/workflows/prettier.yml)
|
|
16
|
+
[](https://oxc.rs/)
|
|
19
17
|
|
|
20
18
|
<img src="https://github.com/asumo-1xts/vitepress-linkcard/blob/main/.github/screen.gif?raw=true" width=90% alt="How it shows" />
|
|
21
19
|
|
|
@@ -38,9 +36,9 @@ pnpm add -D vitepress-linkcard # pnpm
|
|
|
38
36
|
#### `docs/.vitepress/config.ts`
|
|
39
37
|
|
|
40
38
|
```ts
|
|
41
|
-
import { defineConfig } from
|
|
42
|
-
import { linkToCardPlugin } from
|
|
43
|
-
import type { LinkToCardPluginOptions } from
|
|
39
|
+
import { defineConfig } from 'vitepress'
|
|
40
|
+
import { linkToCardPlugin } from 'vitepress-linkcard'
|
|
41
|
+
import type { LinkToCardPluginOptions } from 'vitepress-linkcard'
|
|
44
42
|
|
|
45
43
|
export default defineConfig({
|
|
46
44
|
// ...
|
|
@@ -48,11 +46,11 @@ export default defineConfig({
|
|
|
48
46
|
config: (md) => {
|
|
49
47
|
md.use<LinkToCardPluginOptions>(linkToCardPlugin, {
|
|
50
48
|
// target: "_self" // if needed
|
|
51
|
-
})
|
|
52
|
-
}
|
|
49
|
+
})
|
|
50
|
+
}
|
|
53
51
|
}
|
|
54
52
|
// ...
|
|
55
|
-
})
|
|
53
|
+
})
|
|
56
54
|
```
|
|
57
55
|
|
|
58
56
|
#### `*.md`
|
|
@@ -103,7 +101,7 @@ You can customize:
|
|
|
103
101
|
|
|
104
102
|
#### `docs/.vitepress/theme/index.ts`
|
|
105
103
|
|
|
106
|
-
```
|
|
104
|
+
```ts
|
|
107
105
|
import DefaultTheme from 'vitepress/theme-without-fonts'
|
|
108
106
|
import type { Theme as ThemeConfig } from 'vitepress'
|
|
109
107
|
import './custom.css'
|
|
@@ -129,7 +127,7 @@ You can move it to `.config` directory or edit it if needed.
|
|
|
129
127
|
|
|
130
128
|
When the domain is `github.com`, trimming is performed as shown in the following example to avoid duplication of the title and description.
|
|
131
129
|
|
|
132
|
-
|
|
|
133
|
-
|
|
|
130
|
+
| | Title | Description |
|
|
131
|
+
| ------ | ----------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
134
132
|
| Before | GitHub - asumo-1xts/vitepress-linkcard: A VitePress plugin to generate a pretty linkcard. | A VitePress plugin to generate a pretty linkcard. Contribute to asumo-1xts/vitepress-linkcard development by creating an account on GitHub. |
|
|
135
|
-
| After
|
|
133
|
+
| After | asumo-1xts/vitepress-linkcard | A VitePress plugin to generate a pretty linkcard. |
|
package/dist/.cjs.min.js
CHANGED
package/dist/.esm.min.js
CHANGED
package/package.json
CHANGED
|
@@ -1,20 +1,49 @@
|
|
|
1
1
|
{
|
|
2
|
-
"
|
|
3
|
-
"
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
2
|
+
"name": "vitepress-linkcard",
|
|
3
|
+
"version": "2.1.1",
|
|
4
|
+
"description": "A Vitepress plugin to generate a pretty linkcard with OGP.",
|
|
5
|
+
"keywords": [
|
|
6
|
+
"linkcard",
|
|
7
|
+
"markdown-it",
|
|
8
|
+
"ogp",
|
|
9
|
+
"thumbnail",
|
|
10
|
+
"vitepress",
|
|
11
|
+
"vitepress-plugin"
|
|
12
|
+
],
|
|
9
13
|
"bugs": {
|
|
10
14
|
"url": "https://github.com/asumo-1xts/vitepress-linkcard"
|
|
11
15
|
},
|
|
12
|
-
"
|
|
16
|
+
"license": "MIT",
|
|
17
|
+
"author": "aSumo",
|
|
18
|
+
"repository": {
|
|
19
|
+
"type": "git",
|
|
20
|
+
"url": "git+https://github.com/asumo-1xts/vitepress-linkcard.git"
|
|
21
|
+
},
|
|
22
|
+
"files": [
|
|
23
|
+
"dist",
|
|
24
|
+
"types"
|
|
25
|
+
],
|
|
26
|
+
"type": "module",
|
|
27
|
+
"main": "./dist/.esm.min.js",
|
|
28
|
+
"module": "./dist/.esm.min.js",
|
|
29
|
+
"types": "./types/index.d.ts",
|
|
30
|
+
"publishConfig": {
|
|
31
|
+
"registry": "https://registry.npmjs.org/"
|
|
32
|
+
},
|
|
33
|
+
"scripts": {
|
|
34
|
+
"build": "tsc && rollup -c",
|
|
35
|
+
"clean": "rm -rf dist types",
|
|
36
|
+
"dev": "rollup -c -w",
|
|
37
|
+
"docs": "typedoc",
|
|
38
|
+
"format": "oxfmt --write",
|
|
39
|
+
"lint": "oxlint",
|
|
40
|
+
"lint:github": "oxlint --format=github",
|
|
41
|
+
"type:dts": "tsc --emitDeclarationOnly"
|
|
42
|
+
},
|
|
13
43
|
"devDependencies": {
|
|
14
44
|
"@babel/core": "^7.28.5",
|
|
15
45
|
"@babel/preset-env": "^7.28.5",
|
|
16
46
|
"@babel/preset-typescript": "^7.28.5",
|
|
17
|
-
"@eslint/js": "^9.39.2",
|
|
18
47
|
"@luckrya/utility": "^0.1.1",
|
|
19
48
|
"@rollup/plugin-babel": "^6.1.0",
|
|
20
49
|
"@rollup/plugin-commonjs": "^29.0.0",
|
|
@@ -22,58 +51,22 @@
|
|
|
22
51
|
"@types/babel__core": "^7",
|
|
23
52
|
"@types/markdown-it": "^13.0.2",
|
|
24
53
|
"@types/node": "^25.0.3",
|
|
25
|
-
"eslint": "^9.39.2",
|
|
26
|
-
"eslint-plugin-vue": "^10.6.2",
|
|
27
54
|
"globals": "^16.5.0",
|
|
28
|
-
"jiti": "^2.6.1",
|
|
29
55
|
"markdown-it": "^13.0.2",
|
|
30
|
-
"
|
|
31
|
-
"
|
|
56
|
+
"oxfmt": "^0.26.0",
|
|
57
|
+
"oxlint": "^1.41.0",
|
|
32
58
|
"rollup": "^2.79.2",
|
|
33
59
|
"rollup-plugin-terser": "^7.0.2",
|
|
34
60
|
"typedoc": "^0.28.15",
|
|
35
61
|
"typedoc-theme-hierarchy": "^6.0.0",
|
|
36
62
|
"typescript": "^5.9.3",
|
|
37
|
-
"typescript-eslint": "^8.50.1",
|
|
38
|
-
"vue-eslint-parser": "^10.2.0",
|
|
39
63
|
"xmlhttprequest": "^1.8.0"
|
|
40
64
|
},
|
|
41
|
-
"
|
|
42
|
-
"
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
"thumbnail",
|
|
47
|
-
"typescript",
|
|
48
|
-
"markdown-it",
|
|
49
|
-
"metadata",
|
|
50
|
-
"ogp",
|
|
51
|
-
"linkcard",
|
|
52
|
-
"vite",
|
|
53
|
-
"vitepress"
|
|
54
|
-
],
|
|
55
|
-
"license": "MIT",
|
|
56
|
-
"main": "./dist/.esm.min.js",
|
|
57
|
-
"module": "./dist/.esm.min.js",
|
|
58
|
-
"name": "vitepress-linkcard",
|
|
59
|
-
"packageManager": "yarn@4.9.2",
|
|
60
|
-
"publishConfig": {
|
|
61
|
-
"registry": "https://registry.npmjs.org/"
|
|
62
|
-
},
|
|
63
|
-
"repository": {
|
|
64
|
-
"type": "git",
|
|
65
|
-
"url": "git+https://github.com/asumo-1xts/vitepress-linkcard.git"
|
|
66
|
-
},
|
|
67
|
-
"scripts": {
|
|
68
|
-
"build": "tsc && rollup -c",
|
|
69
|
-
"clean": "rm -rf dist types",
|
|
70
|
-
"dev": "rollup -c -w",
|
|
71
|
-
"docs": "yarn typedoc",
|
|
72
|
-
"format": "yarn prettier --config .vscode/.prettierrc.json --write .config/*.json .github/workflows .vscode src *.json && rm -rf node_modules",
|
|
73
|
-
"lint": "yarn eslint --config .vscode/eslint.config.ts src/**/*",
|
|
74
|
-
"type:dts": "tsc --emitDeclarationOnly"
|
|
65
|
+
"babel": {
|
|
66
|
+
"presets": [
|
|
67
|
+
"@babel/env",
|
|
68
|
+
"@babel/typescript"
|
|
69
|
+
]
|
|
75
70
|
},
|
|
76
|
-
"
|
|
77
|
-
|
|
78
|
-
"version": "2.0.1"
|
|
79
|
-
}
|
|
71
|
+
"packageManager": "yarn@4.9.2"
|
|
72
|
+
}
|