{"name":"@mdit-vue/plugin-title","version":"3.0.0","keywords":["markdown-it","markdown-it-plugin","vue","title"],"author":{"name":"meteorlxy","email":"meteor.lxy@foxmail.com"},"license":"MIT","_id":"@mdit-vue/plugin-title@3.0.0","maintainers":[{"name":"meteorlxy","email":"meteor.lxy@foxmail.com"}],"homepage":"https://github.com/mdit-vue","bugs":{"url":"https://github.com/mdit-vue/mdit-vue/issues"},"dist":{"shasum":"e86c22f9758a03f8290c19b3efcbc338421e386a","tarball":"http://registry-npm.ywwl.com/@mdit-vue/plugin-title/download/@mdit-vue/plugin-title-3.0.0.tgz","fileCount":8,"integrity":"sha512-FSIktCh4X7Sz7SX6/BXZDXqIsjxcxxOO3d56fJhoqUvbCWkVo52ihyKkj6d9ynFIM/IbPCxiIV94H1l4TBErXA==","signatures":[{"sig":"MEYCIQC72UDk7N9gDbmJ7d8x5LpQfLYd2nLFm+yR+tRqYZFewAIhAPhRR5k3BaN+jzCNwDyZ2TQrrg3HQAmyvkr6CKMVqSBM","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":6232,"size":2693,"noattachment":false,"key":"/@mdit-vue/plugin-title/-/@mdit-vue/plugin-title-3.0.0.tgz"},"main":"./dist/index.cjs","type":"module","types":"./dist/index.d.cts","module":"./dist/index.mjs","engines":{"node":">=20.0.0"},"exports":{".":{"import":"./dist/index.mjs","require":"./dist/index.cjs"},"./package.json":"./package.json"},"gitHead":"bbb62a47109c2932505b3f570b963f70d590914f","scripts":{"test":"vitest","build":"tsdown"},"_npmUser":{"name":"meteorlxy","email":"meteor.lxy@foxmail.com"},"repository":{"url":"git+https://github.com/mdit-vue/mdit-vue.git","type":"git"},"_npmVersion":"lerna/4.7.0/node@v22.17.0+arm64 (darwin)","description":"A markdown-it plugin to get markdown page title","directories":{},"_nodeVersion":"22.17.0","dependencies":{"markdown-it":"^14.1.0","@mdit-vue/types":"3.0.0","@mdit-vue/shared":"3.0.0","@types/markdown-it":"^14.1.2"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"tsdown":"^0.14.0","vitest":"^3.2.4","markdown-it-emoji":"^3.0.0","@types/markdown-it-emoji":"^3.0.1"},"_npmOperationalInternal":{"tmp":"tmp/plugin-title_3.0.0_1754898920099_0.22420894591588691","host":"s3://npm-registry-packages-npm-production"},"readme":"# @mdit-vue/plugin-title\n\n[![npm](https://badgen.net/npm/v/@mdit-vue/plugin-title)](https://www.npmjs.com/package/@mdit-vue/plugin-title)\n[![license](https://badgen.net/github/license/mdit-vue/mdit-vue)](https://github.com/mdit-vue/mdit-vue/blob/main/LICENSE)\n\nA [markdown-it](https://github.com/markdown-it/markdown-it) plugin to get page title.\n\n- Extracts title (the content of the first level-1 heading) into markdown-it `env.title`.\n\n## Install\n\n```sh\nnpm i @mdit-vue/plugin-title\n```\n\n## Usage\n\n```ts\nimport { titlePlugin } from '@mdit-vue/plugin-title';\nimport type { MarkdownItEnv } from '@mdit-vue/types';\nimport MarkdownIt from 'markdown-it';\n\nconst md = MarkdownIt({ html: true }).use(titlePlugin);\nconst env: MarkdownItEnv = {};\n\nconst rendered = md.render(\n  `\\\n# h1\n## h2\n### h3\n`,\n  env,\n);\n\nconsole.log(env.title);\n```\n","publish_time":1754898920262,"_cnpm_publish_time":1754898920262,"dist-tags":{"latest":"4.0.0"}}