{"id":15315829,"url":"https://github.com/wobsoriano/vue-markdoc","last_synced_at":"2025-09-12T10:33:06.199Z","repository":{"id":37382433,"uuid":"491792834","full_name":"wobsoriano/vue-markdoc","owner":"wobsoriano","description":"Vue renderer for Markdoc","archived":false,"fork":false,"pushed_at":"2023-08-02T20:56:36.000Z","size":227,"stargazers_count":18,"open_issues_count":1,"forks_count":3,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-04-15T02:19:50.683Z","etag":null,"topics":["markdoc","markdown","vue"],"latest_commit_sha":null,"homepage":"","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/wobsoriano.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2022-05-13T07:05:09.000Z","updated_at":"2024-10-31T01:42:50.000Z","dependencies_parsed_at":"2023-02-10T01:35:14.537Z","dependency_job_id":null,"html_url":"https://github.com/wobsoriano/vue-markdoc","commit_stats":null,"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wobsoriano%2Fvue-markdoc","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wobsoriano%2Fvue-markdoc/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wobsoriano%2Fvue-markdoc/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wobsoriano%2Fvue-markdoc/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/wobsoriano","download_url":"https://codeload.github.com/wobsoriano/vue-markdoc/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248991610,"owners_count":21194904,"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":["markdoc","markdown","vue"],"created_at":"2024-10-01T08:52:26.305Z","updated_at":"2025-04-15T02:19:56.348Z","avatar_url":"https://github.com/wobsoriano.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# vue-markdoc\n\nTransform [Markdoc](https://markdoc.io/) renderable trees to Vue components.\n\n## Installation\n\n```bash\npnpm add @markdoc/markdoc vue-markdoc\n```\n\n## Usage\n\n```html\n\u003cscript setup\u003e\nimport Markdoc from '@markdoc/markdoc'\nimport render from 'vue-markdoc'\n\nconst doc = `\n# Getting started\n\nRun this command to install the Markdoc library:\n`\n\nconst ast = Markdoc.parse(doc)\nconst content = Markdoc.transform(ast)\n\nconst ContentComponent = render(content)\n\u003c/script\u003e\n\n\u003ctemplate\u003e\n  \u003cContentComponent /\u003e\n\u003c/template\u003e\n```\n\n## Rendering Vue components\n\nTo render a Vue component, provide the `components` object as an argument along with the `content`. The `components` object specifies a mapping from your tags and nodes to the corresponding Vue component.\n\n```html\n\u003cscript setup\u003e\nimport Markdoc from '@markdoc/markdoc'\nimport render from 'vue-markdoc'\nimport Callout from './Callout.vue'\n\nconst tags = {\n  callout: {\n    render: Callout,\n    attributes: {}\n  }\n};\n\nconst doc = `\n{% callout %}\nAttention, over here!\n{% /callout %}\n`;\n\nconst ast = Markdoc.parse(doc)\nconst content = Markdoc.transform(ast, { tags })\n\nconst ContentComponent = render(content)\n\u003c/script\u003e\n\n\u003ctemplate\u003e\n  \u003cContentComponent /\u003e\n\u003c/template\u003e\n```\n\n```html\n\u003ctemplate\u003e\n  \u003cdiv class=\"callout\"\u003e\n    \u003cslot /\u003e\n  \u003c/div\u003e\n\u003c/template\u003e\n\n\u003cstyle\u003e\n.callout {...}\n\u003c/style\u003e\n```\n\n## Related\n\n- [unplugin-markdoc](https://github.com/wobsoriano/unplugin-markdoc) - Markdoc plugin for Vite/Webpack.\n\n## License\n\nMIT\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwobsoriano%2Fvue-markdoc","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fwobsoriano%2Fvue-markdoc","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwobsoriano%2Fvue-markdoc/lists"}