{"id":17784335,"url":"https://github.com/2heal1/rspress-plugin-annotation-words","last_synced_at":"2026-01-31T00:30:17.893Z","repository":{"id":259668134,"uuid":"876728873","full_name":"2heal1/rspress-plugin-annotation-words","owner":"2heal1","description":null,"archived":false,"fork":false,"pushed_at":"2024-11-04T09:38:01.000Z","size":74,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2024-12-30T12:17:53.377Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/2heal1.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-10-22T13:12:15.000Z","updated_at":"2024-11-04T09:38:14.000Z","dependencies_parsed_at":"2024-10-27T08:04:43.590Z","dependency_job_id":"3b793fed-e82a-45da-8aee-abc09fd12376","html_url":"https://github.com/2heal1/rspress-plugin-annotation-words","commit_stats":null,"previous_names":["2heal1/rspress-plugin-annotation-words"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/2heal1%2Frspress-plugin-annotation-words","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/2heal1%2Frspress-plugin-annotation-words/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/2heal1%2Frspress-plugin-annotation-words/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/2heal1%2Frspress-plugin-annotation-words/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/2heal1","download_url":"https://codeload.github.com/2heal1/rspress-plugin-annotation-words/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":239780117,"owners_count":19695734,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-27T08:01:43.147Z","updated_at":"2026-01-31T00:30:17.838Z","avatar_url":"https://github.com/2heal1.png","language":"TypeScript","funding_links":[],"categories":["Plugins"],"sub_categories":["Rspress Plugins"],"readme":"# rspress-plugin-annotation-words\n\nA plugin for Rsoress to support annotation words.\n\n## Examples\n[Repo](https://github.com/module-federation/core/blob/main/apps/website-new/rspress.config.ts#L75)\n\n[Docs url](https://module-federation.io/guide/troubleshooting/runtime/RUNTIME-007.html)\n\n![image](https://github.com/user-attachments/assets/5c2f7e87-6c87-473c-b02a-2000856f0105)\n\n## Install\n\n```bash\n# npm\nnpm install rspress-plugin-annotation-words\n# yarn\nyarn add rspress-plugin-annotation-words\n# pnpm\npnpm install rspress-plugin-annotation-words\n```\n\n## Usage\n\n```js\nimport { defineConfig } from 'rspress/config';\nimport { pluginAnnotationWords } from 'rspress-plugin-annotation-words'\nimport path from 'path';\n\nexport default defineConfig({\n  // ...\n  plugins:[pluginAnnotationWords({\n    wordsMapPath:'words-map.json'\n  })],\n});\n```\n\nadd `words-map.json` to `public` folder, the content is like this:\n```json\n{\n  \"word\":{\n    \"id\":\"word\",\n    \"lang\":{\n      \"zh\":{\n        \"aliases\":[\n          {\"key\":\"word aliases\"}\n        ],\n        \"description\":\"描述\",\n        \"related_meta\":{\n          \"docs\":[{\n            \"id\":\"word-docs\",\n            \"title\":\"文档标题（通常用于 rspress 内部链接）\",\n            \"url\":\"/zh/configure/name.html#name\"\n          }],\n          \"links\":[{\n            \"id\":\"word-link\",\n            \"title\":\"外部链接\",\n            \"url\":\"https://github.com/2heal1/rspress-plugin-annotation-words\"\n          }]\n        }\n      },\n      \"en\":{\n        \"aliases\":[\n          {\"key\":\"word aliases\"}\n        ],\n        \"description\":\"word name\",\n        \"related_meta\":{\n          \"docs\":[{\n            \"id\":\"word-docs\",\n            \"title\":\"word title(usually used for rspress internal links)\",\n            \"url\":\"/en/configure/name.html#name\"\n          }],\n          \"links\":[{\n            \"id\":\"word-link\",\n            \"title\":\"external link\",\n            \"url\":\"https://github.com/2heal1/rspress-plugin-annotation-words\"\n          }]\n        }\n      }\n    }\n  },\n}\n\n```\n\n## Options\n\n```ts\ninterface Options {\n  /**\n   * words map path\n   */\n  wordsMapPath:string;\n  ignoreWords?: string[];\n  ignorePaths?: RegExp[];\n}\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2F2heal1%2Frspress-plugin-annotation-words","html_url":"https://awesome.ecosyste.ms/projects/github.com%2F2heal1%2Frspress-plugin-annotation-words","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2F2heal1%2Frspress-plugin-annotation-words/lists"}