\u003C/ClientOnly>`\n }\n return result;\n }`\n这段代码alt的值获取不到。\n\n### Reproduction\n\nconfig.js 的markdown配置中配置如下:\n` md.renderer.rules.image = (tokens, idx, options, env, self) => {\n const token = tokens[idx];\n let alt = token.attrGet('alt');\n console.log(\"alt :\"+ alt);\n let result = self.renderToken(tokens, idx, options);\n if (alt) {\n result += `\\n\u003CClientOnly>\u003CTableCaption title='${alt}' />\u003C/ClientOnly>`\n }\n return result;\n }`\n\n### Expected behavior\n\n希望可以取到alt属性值。\n\n### System Info\n\n```Text\nSystem:\n OS: macOS 15.3.1\n CPU: (8) arm64 Apple M1\n Memory: 77.58 MB / 8.00 GB\n Shell: 5.9 - /bin/zsh\n Binaries:\n Node: 23.6.0 - ~/.nvm/versions/node/v23.6.0/bin/node\n npm: 10.9.2 - ~/.nvm/versions/node/v23.6.0/bin/npm\n pnpm: 8.15.0 - ~/Library/pnpm/pnpm\n Browsers:\n Chrome: 133.0.6943.142\n Safari: 18.3\n npmPackages:\n vitepress: ^1.6.3 => 1.6.3\n```\n\n### Additional context\n\n_No response_\n\n### Validations\n\n- [x] Check if you're on the [latest VitePress version](https://github.com/vuejs/vitepress/releases/latest).\n- [x] Follow our [Code of Conduct](https://vuejs.org/about/coc.html)\n- [x] Read the [docs](https://vitepress.dev).\n- [x] Check that there isn't already an issue that reports the same bug to avoid creating a duplicate.",[3122],{"name":3123,"color":3124},"bug: pending triage","e99695",4607,"markdown 图片自定义渲染,token.attrGet('alt') 获取不到值","2025-03-17T04:44:43Z","https://github.com/vuejs/vitepress/issues/4607",0.7356471,["Reactive",3131],{},["Set"],["ShallowReactive",3134],{"$fTRc1wZytZ_XrK4EfJfei_Sz-An4H4Yy6syhVxH_PVJc":-1,"$fhCr76XoB6HNSnnq0jrzXedsj6G2zIvQmsVNCF7e96AA":-1},"/vuejs/vitepress/4599"]