typedoc-plugin-hash-link-references 0.1.0 → 1.0.0
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 +49 -6
- package/dist/core.d.ts +2 -2
- package/dist/core.d.ts.map +1 -1
- package/dist/core.js +3 -2
- package/dist/core.js.map +1 -1
- package/dist/plugin.d.ts +1 -1
- package/dist/plugin.d.ts.map +1 -1
- package/dist/plugin.js.map +1 -1
- package/package.json +128 -114
package/README.md
CHANGED
|
@@ -2,16 +2,24 @@
|
|
|
2
2
|
|
|
3
3
|
[](https://github.com/Nick2bad4u/typedoc-plugin-hash-link-references/blob/main/LICENSE) [](https://www.npmjs.com/package/typedoc-plugin-hash-link-references) [](https://github.com/Nick2bad4u/typedoc-plugin-hash-link-references/releases) [](https://github.com/Nick2bad4u/typedoc-plugin-hash-link-references/stargazers) [](https://github.com/Nick2bad4u/typedoc-plugin-hash-link-references/forks) [](https://github.com/Nick2bad4u/typedoc-plugin-hash-link-references/issues) [](https://codecov.io/gh/Nick2bad4u/typedoc-plugin-hash-link-references) [](https://github.com/Nick2bad4u/typedoc-plugin-hash-link-references/actions)
|
|
4
4
|
|
|
5
|
-
TypeDoc
|
|
6
|
-
TypeDoc declaration references
|
|
5
|
+
Write TypeDoc inline links that stay readable in editors, then publish them as
|
|
6
|
+
TypeDoc declaration references.
|
|
7
|
+
|
|
8
|
+
`typedoc-plugin-hash-link-references` rewrites inline TypeDoc link tags such as
|
|
9
|
+
`{@link src/widgets/Button.ts#Button}` into
|
|
10
|
+
`{@link src/widgets/Button.ts!Button}` before TypeDoc resolves links. That lets
|
|
11
|
+
source comments keep the familiar `path#Symbol` shape while TypeDoc receives the
|
|
12
|
+
`path!Symbol` declaration-reference syntax it expects.
|
|
7
13
|
|
|
8
14
|
## Install
|
|
9
15
|
|
|
10
16
|
```sh
|
|
11
|
-
npm install --save-dev typedoc-plugin-hash-link-references
|
|
17
|
+
npm install --save-dev typedoc typedoc-plugin-hash-link-references
|
|
12
18
|
```
|
|
13
19
|
|
|
14
|
-
##
|
|
20
|
+
## Configure
|
|
21
|
+
|
|
22
|
+
Add the plugin to your TypeDoc config:
|
|
15
23
|
|
|
16
24
|
```json
|
|
17
25
|
{
|
|
@@ -19,5 +27,40 @@ npm install --save-dev typedoc-plugin-hash-link-references
|
|
|
19
27
|
}
|
|
20
28
|
```
|
|
21
29
|
|
|
22
|
-
|
|
23
|
-
|
|
30
|
+
If you use a JavaScript or TypeScript TypeDoc config, the same value belongs in
|
|
31
|
+
the `plugin` array.
|
|
32
|
+
|
|
33
|
+
## Link Behavior
|
|
34
|
+
|
|
35
|
+
The plugin rewrites only inline TypeDoc tags:
|
|
36
|
+
|
|
37
|
+
- `{@link path/to/file.ts#ExportedName}`
|
|
38
|
+
- `{@linkcode path/to/file.ts#ExportedName}`
|
|
39
|
+
- `{@linkplain path/to/file.ts#ExportedName}`
|
|
40
|
+
|
|
41
|
+
It leaves URL-like targets, anchor-only links, existing TypeDoc
|
|
42
|
+
`path!Symbol` references, and plain text untouched.
|
|
43
|
+
|
|
44
|
+
## Example
|
|
45
|
+
|
|
46
|
+
```ts
|
|
47
|
+
/**
|
|
48
|
+
* Creates the default widget.
|
|
49
|
+
*
|
|
50
|
+
* @see {@link src/widgets/create-widget.ts#CreateWidgetOptions}
|
|
51
|
+
*/
|
|
52
|
+
export function createWidget() {}
|
|
53
|
+
```
|
|
54
|
+
|
|
55
|
+
TypeDoc receives the link target as
|
|
56
|
+
`src/widgets/create-widget.ts!CreateWidgetOptions`, so generated docs can resolve
|
|
57
|
+
the declaration reference without making source comments harder to read.
|
|
58
|
+
|
|
59
|
+
## API
|
|
60
|
+
|
|
61
|
+
Most projects only need the TypeDoc plugin entrypoint. The package also exports
|
|
62
|
+
`typedoc-plugin-hash-link-references/core` for tests or custom integrations that
|
|
63
|
+
want to call the rewrite helper directly.
|
|
64
|
+
|
|
65
|
+
Full docs and generated API reference are published with the repository site:
|
|
66
|
+
<https://nick2bad4u.github.io/typedoc-plugin-hash-link-references/>.
|
package/dist/core.d.ts
CHANGED
|
@@ -5,7 +5,7 @@ import type { Comment, CommentDisplayPart } from "typedoc";
|
|
|
5
5
|
*
|
|
6
6
|
* @param comment - Comment to update.
|
|
7
7
|
*/
|
|
8
|
-
export declare function convertHashLinksToBangLinksInComment(comment: Comment): void;
|
|
8
|
+
export declare function convertHashLinksToBangLinksInComment(comment: Readonly<Comment>): void;
|
|
9
9
|
/**
|
|
10
10
|
* Rewrites `module#Export` to `module!Export` for module-source-like
|
|
11
11
|
* references. Whitespace and `| label` suffixes are preserved.
|
|
@@ -19,5 +19,5 @@ export declare function convertHashLinksToBangLinksInInlineTagText(inlineTagText
|
|
|
19
19
|
* @param parts - Display parts collection whose inline-tag text may be
|
|
20
20
|
* rewritten.
|
|
21
21
|
*/
|
|
22
|
-
export declare function convertHashLinksToBangLinksInParts(parts: CommentDisplayPart[]): void;
|
|
22
|
+
export declare function convertHashLinksToBangLinksInParts(parts: readonly Readonly<CommentDisplayPart>[]): void;
|
|
23
23
|
//# sourceMappingURL=core.d.ts.map
|
package/dist/core.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"core.d.ts","sourceRoot":"","sources":["../src/core.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAE,kBAAkB,EAAE,MAAM,SAAS,CAAC;AAmB3D;;;;;GAKG;AACH,wBAAgB,oCAAoC,
|
|
1
|
+
{"version":3,"file":"core.d.ts","sourceRoot":"","sources":["../src/core.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAE,kBAAkB,EAAE,MAAM,SAAS,CAAC;AAmB3D;;;;;GAKG;AACH,wBAAgB,oCAAoC,CAChD,OAAO,EAAE,QAAQ,CAAC,OAAO,CAAC,GAC3B,IAAI,CAKN;AAED;;;;;GAKG;AACH,wBAAgB,0CAA0C,CACtD,aAAa,EAAE,MAAM,GACtB,MAAM,CAwCR;AAED;;;;;GAKG;AACH,wBAAgB,kCAAkC,CAC9C,KAAK,EAAE,SAAS,QAAQ,CAAC,kBAAkB,CAAC,EAAE,GAC/C,IAAI,CAgBN"}
|
package/dist/core.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { setHas } from "ts-extras";
|
|
1
|
+
import { safeCastTo, setHas } from "ts-extras";
|
|
2
2
|
const URL_LIKE_SCHEMES = new Set([
|
|
3
3
|
"blob",
|
|
4
4
|
"data",
|
|
@@ -63,7 +63,8 @@ export function convertHashLinksToBangLinksInInlineTagText(inlineTagText) {
|
|
|
63
63
|
* rewritten.
|
|
64
64
|
*/
|
|
65
65
|
export function convertHashLinksToBangLinksInParts(parts) {
|
|
66
|
-
for (const
|
|
66
|
+
for (const readonlyPart of parts) {
|
|
67
|
+
const part = safeCastTo(readonlyPart);
|
|
67
68
|
if (part.kind === "inline-tag" && setHas(INLINE_LINK_TAGS, part.tag)) {
|
|
68
69
|
const rewritten = convertHashLinksToBangLinksInInlineTagText(part.text);
|
|
69
70
|
if (rewritten !== part.text) {
|
package/dist/core.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"core.js","sourceRoot":"","sources":["../src/core.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,MAAM,EAAE,MAAM,WAAW,CAAC;
|
|
1
|
+
{"version":3,"file":"core.js","sourceRoot":"","sources":["../src/core.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,UAAU,EAAE,MAAM,EAAE,MAAM,WAAW,CAAC;AAE/C,MAAM,gBAAgB,GAAwB,IAAI,GAAG,CAAC;IAClD,MAAM;IACN,MAAM;IACN,MAAM;IACN,QAAQ;IACR,KAAK;IACL,KAAK;CACR,CAAC,CAAC;AAEH,MAAM,gBAAgB,GAA8B,IAAI,GAAG,CAAC;IACxD,OAAO;IACP,WAAW;IACX,YAAY;CACf,CAAC,CAAC;AAEH;;;;;GAKG;AACH,MAAM,UAAU,oCAAoC,CAChD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,CAAC,GAAG,CAAC;QAC1B,YAAY,CAAC,QAAQ,CAAC,GAAG,CAAC,CAC7B,CAAC;AACN,CAAC;AAED,SAAS,SAAS,CAAC,YAAoB;IACnC,IAAI,YAAY,CAAC,QAAQ,CAAC,KAAK,CAAC,EAAE,CAAC;QAC/B,OAAO,IAAI,CAAC;IAChB,CAAC;IAED,MAAM,UAAU,GAAG,YAAY,CAAC,OAAO,CAAC,GAAG,CAAC,CAAC;IAC7C,IAAI,UAAU,IAAI,CAAC,EAAE,CAAC;QAClB,OAAO,KAAK,CAAC;IACjB,CAAC;IAED,MAAM,MAAM,GAAG,YAAY,CAAC,KAAK,CAAC,CAAC,EAAE,UAAU,CAAC,CAAC;IACjD,IACI,aAAa,CAAC,IAAI,CAAC,MAAM,CAAC;QAC1B,CAAC,YAAY,CAAC,KAAK,CAAC,UAAU,GAAG,CAAC,CAAC,CAAC,QAAQ,CAAC,GAAG,CAAC;YAC7C,YAAY,CAAC,KAAK,CAAC,UAAU,GAAG,CAAC,CAAC,CAAC,QAAQ,CAAC,IAAI,CAAC,CAAC,EACxD,CAAC;QACC,OAAO,KAAK,CAAC;IACjB,CAAC;IAED,OAAO,MAAM,CAAC,gBAAgB,EAAE,MAAM,CAAC,WAAW,EAAE,CAAC,CAAC;AAC1D,CAAC"}
|
package/dist/plugin.d.ts
CHANGED
package/dist/plugin.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"plugin.d.ts","sourceRoot":"","sources":["../src/plugin.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,KAAK,WAAW,EAAa,MAAM,SAAS,CAAC;AAQtD;;;;GAIG;AACH,wBAAgB,IAAI,CAAC,GAAG,EAAE,WAAW,GAAG,IAAI,
|
|
1
|
+
{"version":3,"file":"plugin.d.ts","sourceRoot":"","sources":["../src/plugin.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,KAAK,WAAW,EAAa,MAAM,SAAS,CAAC;AAQtD;;;;GAIG;AACH,wBAAgB,IAAI,CAAC,GAAG,EAAE,QAAQ,CAAC,WAAW,CAAC,GAAG,IAAI,CAcrD"}
|
package/dist/plugin.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"plugin.js","sourceRoot":"","sources":["../src/plugin.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,WAAW,CAAC;AACzC,OAAO,EAAoB,SAAS,EAAE,MAAM,SAAS,CAAC;AAEtD,OAAO,EAAE,oCAAoC,EAAE,MAAM,WAAW,CAAC;AAEjE,gFAAgF;AAChF,iDAAiD;AACjD,MAAM,iCAAiC,GAAG,EAAE,CAAC;AAE7C;;;;GAIG;AACH,MAAM,UAAU,IAAI,CAAC,
|
|
1
|
+
{"version":3,"file":"plugin.js","sourceRoot":"","sources":["../src/plugin.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,WAAW,CAAC;AACzC,OAAO,EAAoB,SAAS,EAAE,MAAM,SAAS,CAAC;AAEtD,OAAO,EAAE,oCAAoC,EAAE,MAAM,WAAW,CAAC;AAEjE,gFAAgF;AAChF,iDAAiD;AACjD,MAAM,iCAAiC,GAAG,EAAE,CAAC;AAE7C;;;;GAIG;AACH,MAAM,UAAU,IAAI,CAAC,GAA0B;IAC3C,GAAG,CAAC,SAAS,CAAC,EAAE,CACZ,SAAS,CAAC,iBAAiB,EAC3B,CAAC,OAAO,EAAE,EAAE;QACR,KAAK,MAAM,UAAU,IAAI,YAAY,CACjC,OAAO,CAAC,OAAO,CAAC,WAAW,CAC9B,EAAE,CAAC;YACA,IAAI,UAAU,CAAC,OAAO,EAAE,CAAC;gBACrB,oCAAoC,CAAC,UAAU,CAAC,OAAO,CAAC,CAAC;YAC7D,CAAC;QACL,CAAC;IACL,CAAC,EACD,iCAAiC,CACpC,CAAC;AACN,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,114 +1,128 @@
|
|
|
1
|
-
{
|
|
2
|
-
|
|
3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
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://www.schemastore.org/package.json",
|
|
3
|
+
"name": "typedoc-plugin-hash-link-references",
|
|
4
|
+
"version": "1.0.0",
|
|
5
|
+
"private": false,
|
|
6
|
+
"description": "TypeDoc plugin that rewrites VS Code-friendly path#Symbol links into TypeDoc path!Symbol declaration references.",
|
|
7
|
+
"keywords": [
|
|
8
|
+
"documentation",
|
|
9
|
+
"typedoc",
|
|
10
|
+
"typedoc-plugin",
|
|
11
|
+
"declaration-reference",
|
|
12
|
+
"markdown"
|
|
13
|
+
],
|
|
14
|
+
"homepage": "https://github.com/Nick2bad4u/typedoc-plugin-hash-link-references#readme",
|
|
15
|
+
"bugs": {
|
|
16
|
+
"url": "https://github.com/Nick2bad4u/typedoc-plugin-hash-link-references/issues",
|
|
17
|
+
"email": "20943337+Nick2bad4u@users.noreply.github.com"
|
|
18
|
+
},
|
|
19
|
+
"repository": {
|
|
20
|
+
"type": "git",
|
|
21
|
+
"url": "git+https://github.com/Nick2bad4u/typedoc-plugin-hash-link-references.git"
|
|
22
|
+
},
|
|
23
|
+
"license": "MIT",
|
|
24
|
+
"author": "Nick2bad4u <20943337+Nick2bad4u@users.noreply.github.com> (https://github.com/Nick2bad4u)",
|
|
25
|
+
"contributors": [
|
|
26
|
+
{
|
|
27
|
+
"name": "Nick2bad4u",
|
|
28
|
+
"email": "20943337+Nick2bad4u@users.noreply.github.com",
|
|
29
|
+
"url": "https://github.com/Nick2bad4u"
|
|
30
|
+
}
|
|
31
|
+
],
|
|
32
|
+
"sideEffects": false,
|
|
33
|
+
"type": "module",
|
|
34
|
+
"exports": {
|
|
35
|
+
".": {
|
|
36
|
+
"types": "./dist/plugin.d.ts",
|
|
37
|
+
"import": "./dist/plugin.js"
|
|
38
|
+
},
|
|
39
|
+
"./core": {
|
|
40
|
+
"types": "./dist/core.d.ts",
|
|
41
|
+
"import": "./dist/core.js"
|
|
42
|
+
},
|
|
43
|
+
"./package.json": "./package.json"
|
|
44
|
+
},
|
|
45
|
+
"main": "./dist/plugin.js",
|
|
46
|
+
"types": "./dist/plugin.d.ts",
|
|
47
|
+
"files": [
|
|
48
|
+
"dist",
|
|
49
|
+
"CHANGELOG.md"
|
|
50
|
+
],
|
|
51
|
+
"workspaces": [
|
|
52
|
+
"docs/docusaurus"
|
|
53
|
+
],
|
|
54
|
+
"scripts": {
|
|
55
|
+
"build": "npm run clean:dist && npx -y tsc -p tsconfig.build.json",
|
|
56
|
+
"build:runtime": "npm run build",
|
|
57
|
+
"changelog:generate": "npx -y git-cliff --config cliff.toml --output CHANGELOG.md",
|
|
58
|
+
"changelog:preview": "npx -y git-cliff --config cliff.toml --unreleased",
|
|
59
|
+
"changelog:release-notes": "npx -y git-cliff --config cliff.toml --current --strip all",
|
|
60
|
+
"clean:dist": "node -e \"require('node:fs').rmSync('dist',{recursive:true,force:true})\"",
|
|
61
|
+
"clean:docs": "node -e \"require('node:fs').rmSync('docs/docusaurus/build',{recursive:true,force:true});require('node:fs').rmSync('docs/docusaurus/.docusaurus',{recursive:true,force:true});require('node:fs').rmSync('docs/docusaurus/site-docs/developer/api',{recursive:true,force:true})\"",
|
|
62
|
+
"coverage": "npm run build && npx -y vitest run --coverage",
|
|
63
|
+
"docs:api": "npm run --workspace docs/docusaurus docs:api",
|
|
64
|
+
"docs:build": "npm run --workspace docs/docusaurus build",
|
|
65
|
+
"docs:build:local": "npm run --workspace docs/docusaurus build:local",
|
|
66
|
+
"docs:serve": "npm run --workspace docs/docusaurus serve",
|
|
67
|
+
"docs:start": "npm run --workspace docs/docusaurus start",
|
|
68
|
+
"docs:typecheck": "npm run --workspace docs/docusaurus typecheck",
|
|
69
|
+
"lint": "npx -y eslint . --cache --cache-strategy content --cache-location .cache/.eslintcache",
|
|
70
|
+
"lint:css": "npx -y stylelint --cache --config stylelint.config.mjs --cache-strategy content --cache-location .cache/stylelintcache \"docs/docusaurus/src/**/*.css\"",
|
|
71
|
+
"lint:css:fix": "npx -y stylelint --cache --config stylelint.config.mjs --cache-strategy content --cache-location .cache/stylelintcache \"docs/docusaurus/src/**/*.css\" --fix",
|
|
72
|
+
"lint:package": "npx -y sort-package-json --check package.json docs/docusaurus/package.json && npx -y npmPkgJsonLint . --configFile .npmpackagejsonlintrc.json --ignorePath .npmpackagejsonlintignore",
|
|
73
|
+
"lint:package:fix": "npx -y sort-package-json package.json docs/docusaurus/package.json",
|
|
74
|
+
"lint:prettier": "npx -y prettier . --log-level warn --cache --cache-location=.cache/.prettier-cache --cache-strategy=content --check",
|
|
75
|
+
"lint:prettier:fix": "npx -y prettier . --log-level warn --cache --cache-location=.cache/.prettier-cache --cache-strategy=content --write",
|
|
76
|
+
"lint:publint": "npx -y publint",
|
|
77
|
+
"lint:remark": "remark . --frail --ignore-path .remarkignore",
|
|
78
|
+
"lint:remark:fix": "remark . --ignore-path .remarkignore --output",
|
|
79
|
+
"prepack": "npm run build",
|
|
80
|
+
"package:check": "npm pack --dry-run && npx -y publint && npx -y attw --pack . --profile esm-only",
|
|
81
|
+
"prepublishOnly": "npm run release:check",
|
|
82
|
+
"release:check": "npm run release:verify",
|
|
83
|
+
"release:verify": "npm run lint && npm run lint:css && npm run typecheck && npm run test && npm run docs:build && npm run lint:remark && npm run lint:prettier && npm run lint:package && npm run package:check",
|
|
84
|
+
"test": "npm run build && npx -y vitest run",
|
|
85
|
+
"typecheck": "npx -y tsc -p tsconfig.json --noEmit && npm run docs:typecheck",
|
|
86
|
+
"types:update": "npx typesync",
|
|
87
|
+
"update-actions": "npx actions-up --yes --style sha",
|
|
88
|
+
"update-deps": "npx ncu -i --install never && npm update --force && npm install --force",
|
|
89
|
+
"verify": "npm run release:verify"
|
|
90
|
+
},
|
|
91
|
+
"dependencies": {
|
|
92
|
+
"ts-extras": "^1.0.0"
|
|
93
|
+
},
|
|
94
|
+
"devDependencies": {
|
|
95
|
+
"@arethetypeswrong/cli": "^0.18.3",
|
|
96
|
+
"@types/node": "^25.9.3",
|
|
97
|
+
"@vitest/coverage-v8": "^4.1.9",
|
|
98
|
+
"eslint": "^10.5.0",
|
|
99
|
+
"eslint-config-nick2bad4u": "^2.0.0",
|
|
100
|
+
"git-cliff": "^2.13.1",
|
|
101
|
+
"npm-package-json-lint": "^10.4.1",
|
|
102
|
+
"npm-package-json-lint-config-nick2bad4u": "^1.0.3",
|
|
103
|
+
"prettier": "^3.8.4",
|
|
104
|
+
"prettier-config-nick2bad4u": "^1.0.17",
|
|
105
|
+
"publint": "^0.3.21",
|
|
106
|
+
"remark": "^15.0.1",
|
|
107
|
+
"remark-cli": "^12.0.1",
|
|
108
|
+
"remark-config-nick2bad4u": "^1.0.8",
|
|
109
|
+
"sort-package-json": "^4.0.0",
|
|
110
|
+
"stylelint": "^17.13.0",
|
|
111
|
+
"stylelint-config-nick2bad4u": "^1.0.19",
|
|
112
|
+
"typedoc": "^0.28.19",
|
|
113
|
+
"typescript": "^6.0.3",
|
|
114
|
+
"vitest": "^4.1.9"
|
|
115
|
+
},
|
|
116
|
+
"peerDependencies": {
|
|
117
|
+
"typedoc": ">=0.28.0"
|
|
118
|
+
},
|
|
119
|
+
"packageManager": "npm@11.17.0",
|
|
120
|
+
"engines": {
|
|
121
|
+
"node": ">=22.0.0"
|
|
122
|
+
},
|
|
123
|
+
"publishConfig": {
|
|
124
|
+
"provenance": true,
|
|
125
|
+
"registry": "https://registry.npmjs.org/"
|
|
126
|
+
},
|
|
127
|
+
"readme": "README.md"
|
|
128
|
+
}
|