{"id":20221055,"url":"https://github.com/christoph-jerolimov/react-showdown","last_synced_at":"2026-01-08T20:10:17.766Z","repository":{"id":37732948,"uuid":"47227342","full_name":"christoph-jerolimov/react-showdown","owner":"christoph-jerolimov","description":"Render React components within markdown and markdown as React components!","archived":false,"fork":false,"pushed_at":"2023-06-09T21:09:40.000Z","size":440,"stargazers_count":122,"open_issues_count":9,"forks_count":33,"subscribers_count":6,"default_branch":"master","last_synced_at":"2024-12-13T22:45:27.737Z","etag":null,"topics":["markdown","react","react-components","reactjs","showdown"],"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/christoph-jerolimov.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":"2015-12-02T00:59:57.000Z","updated_at":"2024-11-17T00:27:57.000Z","dependencies_parsed_at":"2024-06-18T13:55:05.295Z","dependency_job_id":"6b91eaaf-85fd-4a31-afd6-b09f030f7d2f","html_url":"https://github.com/christoph-jerolimov/react-showdown","commit_stats":null,"previous_names":["christoph-jerolimov/react-showdown"],"tags_count":20,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/christoph-jerolimov%2Freact-showdown","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/christoph-jerolimov%2Freact-showdown/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/christoph-jerolimov%2Freact-showdown/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/christoph-jerolimov%2Freact-showdown/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/christoph-jerolimov","download_url":"https://codeload.github.com/christoph-jerolimov/react-showdown/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":230431103,"owners_count":18224655,"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":["markdown","react","react-components","reactjs","showdown"],"created_at":"2024-11-14T06:51:08.525Z","updated_at":"2026-01-08T20:10:17.691Z","avatar_url":"https://github.com/christoph-jerolimov.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# react-showdown [![Build status][travis-image]][travis-url] [![Test coverage][coveralls-image]][coveralls-url] [![Dependency Status][dependency-image]][dependency-url]\n\n\u003e Render [React](http://facebook.github.io/react/index.html)\n\u003e [components](http://facebook.github.io/react/docs/component-specs.html)\n\u003e within markdown and markdown as React components!\n\n## Features\n\n* **Render markdown as React components.**\n* **Render React components within the markdown!**\n* Full TypeScript Support.\n* Fully tested.\n* Supports all [Showdown extensions](https://github.com/showdownjs/showdown/wiki/extensions), like the\n  [Twitter Extension](https://github.com/showdownjs/twitter-extension) and the\n  [Youtube Extension](https://github.com/showdownjs/youtube-extension).\n* New in 2.0: Supports Showdown Flavors!\n* New in 2.1:\n  * Fixes [#54](https://github.com/jerolimov/react-showdown/issues/54): Missing content after a self-closing component. This was fixed by setting the default value of showdown config `recognizeSelfClosing` to `true`. Thanks [@n1ru4l](https://github.com/n1ru4l)\n  * New feature: add new optional `sanitizeHtml` prop for sanitizing html before it was rendered. Thanks [@n1ru4l](https://github.com/n1ru4l) aswell.\n\n## Installation\n\n```bash\nnpm install --save react-showdown\n```\n\nor\n\n```bash\nyarn add react-showdown\n```\n\n## Use as React component\n\nExample with ES6/JSX:\n\n```jsx\nimport React from 'react';\nimport MarkdownView from 'react-showdown';\n\nexport default function App() {\n  const markdown = `\n# Welcome to React Showdown :+1:\n\nTo get started, edit the markdown in \\`example/src/App.tsx\\`.\n\n| Column 1 | Column 2 |\n|----------|----------|\n| A1       | B1       |\n| A2       | B2       |\n`;\n\n  return (\n    \u003cMarkdownView\n      markdown={markdown}\n      options={{ tables: true, emoji: true }}\n    /\u003e\n  );\n};\n```\n\nUse a React component and use it within the markdown with ES6 / TypeScript:\n\n```jsx\nimport MarkdownView from 'react-showdown';\n\nfunction CustomComponent({ name }: { name: string }) {\n  return \u003cspan\u003eHello {name}!\u003c/span\u003e;\n}\n\nconst markdown = `\n# A custom component:\n\n\u003cCustomComponent name=\"world\" /\u003e`;\n\n\u003cMarkdownView markdown={markdown} components={{ CustomComponent }} /\u003e\n```\n\n## Available props\n\n* markdown, string, required\n* flavor, Flavor, optional\n* options, ConverterOptions, optional\n* extensions, showdown extensions, optional\n* components, components, optional \n\nConverter options will be pushed forward to the showdown converter, please\ncheckout the [valid options section](https://github.com/showdownjs/showdown#valid-options).\n\n## Credits\n\nProject is based on the markdown parser [Showdown](https://github.com/showdownjs/showdown) and\nthe html parser [htmlparser2](https://github.com/fb55/htmlparser2/).\n\n## Alternatives\n\n* [reactdown](https://github.com/andreypopp/reactdown)\n* [react-markdown](https://github.com/rexxars/react-markdown), based on\n  [commonmark.js](https://github.com/jgm/commonmark.js)\n* [commonmark-react-renderer](https://github.com/rexxars/commonmark-react-renderer), based on\n  [commonmark.js](https://github.com/jgm/commonmark.js)\n\n[travis-image]: https://img.shields.io/travis/jerolimov/react-showdown/master.svg?style=flat-square\n[travis-url]: https://travis-ci.org/jerolimov/react-showdown\n[coveralls-image]: https://img.shields.io/coveralls/jerolimov/react-showdown/master.svg?style=flat-square\n[coveralls-url]: https://coveralls.io/r/jerolimov/react-showdown\n[dependency-image]: http://img.shields.io/david/jerolimov/react-showdown.svg?style=flat-square\n[dependency-url]: https://david-dm.org/jerolimov/react-showdown\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fchristoph-jerolimov%2Freact-showdown","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fchristoph-jerolimov%2Freact-showdown","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fchristoph-jerolimov%2Freact-showdown/lists"}