{"id":13726003,"url":"https://github.com/lwansbrough/react-native-markdown","last_synced_at":"2025-04-06T23:17:38.053Z","repository":{"id":29911929,"uuid":"33457765","full_name":"lwansbrough/react-native-markdown","owner":"lwansbrough","description":"Markdown component for React Native","archived":false,"fork":false,"pushed_at":"2016-08-27T17:16:45.000Z","size":182,"stargazers_count":277,"open_issues_count":17,"forks_count":77,"subscribers_count":7,"default_branch":"master","last_synced_at":"2025-04-06T19:14:09.971Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","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/lwansbrough.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":"2015-04-05T22:44:57.000Z","updated_at":"2024-10-10T10:57:23.000Z","dependencies_parsed_at":"2022-08-31T17:21:07.366Z","dependency_job_id":null,"html_url":"https://github.com/lwansbrough/react-native-markdown","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lwansbrough%2Freact-native-markdown","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lwansbrough%2Freact-native-markdown/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lwansbrough%2Freact-native-markdown/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lwansbrough%2Freact-native-markdown/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/lwansbrough","download_url":"https://codeload.github.com/lwansbrough/react-native-markdown/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247563941,"owners_count":20958971,"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-08-03T01:02:46.825Z","updated_at":"2025-04-06T23:17:38.036Z","avatar_url":"https://github.com/lwansbrough.png","language":"JavaScript","readme":"# react-native-markdown\n\nA component for rendering Markdown in React Native. Pull requests welcome.\n\n## Known issues\n\n- Due to [a bug](https://github.com/facebook/react-native/issues/824) in underlying layout engine for React Native ([facebook/css-layout](https://github.com/facebook/css-layout)), this module will put your application in an infinite loop unless you patch the upstream changes from `css-layout`'s' `Layout.c` and `Layout.h` files.\n\n## Getting started\n\n1. `npm install react-native-markdown --save`\n\n## Usage\n\nAll you need is to `require` the `react-native-markdown` module and then use the\n`\u003cMarkdown/\u003e` tag.\n\n```javascript\nvar React = require('react-native');\nvar {\n  AppRegistry,\n  StyleSheet,\n  View\n} = React;\nvar Markdown = require('react-native-markdown');\n\nvar mdApp = React.createClass({\n  render: function() {\n    return (\n      \u003cView\u003e\n        \u003cMarkdown\u003e\n          Some *really* basic **Markdown**.\n          {'\\n\\n'}\n          | # | Name   | Age |{'\\n'}\n          |---|--------|-----|{'\\n'}\n          | 1 | John   | 19  |{'\\n'}\n          | 2 | Sally  | 18  |{'\\n'}\n          | 3 | Stream | 20  |{'\\n'}\n        \u003c/Markdown\u003e\n      \u003c/View\u003e\n    );\n  }\n});\n\nAppRegistry.registerComponent('mdApp', () =\u003e mdApp);\n```\n\n## Properties\n\n#### `style`\n\nDefault style properties will be applied to the markdown. You will likely want to customize these styles, the following properties can be used to modify the rendered elements:\n\n*Note: The text inside the parentheses denotes the element type.*\n\n- `autolink` (`\u003cText\u003e`) - WIP\n- `blockQuote` (`\u003cText\u003e`) - WIP\n- `br` (`\u003cText\u003e`)\n- `codeBlock` (`\u003cView\u003e`) - WIP\n- `del` (`\u003cText\u003e`)\n- `em` (`\u003cText\u003e`)\n- `heading` (`\u003cText\u003e`) - Also `heading1` through `heading6`\n- `hr` (`\u003cView\u003e`)\n- `image` (`\u003cImage\u003e`) - Implemented but size is fixed to `50x50` until auto width is supported by React Native.\n- `inlineCode` (`\u003cText\u003e`)\n- `link` (`\u003cText\u003e`) - WIP\n- `list` (`\u003cView\u003e`) - Also `listItem` (`\u003cView\u003e`), `listItemBullet` (`\u003cText\u003e`) and `listItemNumber` (`\u003cText\u003e`)\n- `mailto` (`\u003cText\u003e`) - WIP\n- `newline` (`\u003cText\u003e`) - WIP\n- `paragraph` (`\u003cView\u003e`)\n- `plainText` (`\u003cText\u003e`) - Use for styling text without any associated styles\n- `strong` (`\u003cText\u003e`)\n- `table` (`\u003cView\u003e`)\n- `tableHeader` (`\u003cView\u003e`)\n- `tableHeaderCell` (`\u003cText\u003e`)\n- `tableRow` (`\u003cView\u003e`)\n- `tableRowCell` (`\u003cView\u003e`)\n- `tableRowLast` (`\u003cView\u003e`, inherits from `tableRow`)\n- `text` (`\u003cText\u003e`) - Inherited by all text based elements\n- `u` (`\u003cView\u003e`)\n- `url` (`\u003cText\u003e`)\n- `view` (`\u003cView\u003e`) - This is the container `View` that the Markdown is rendered in.\n","funding_links":[],"categories":["Components","Libraries","JavaScript"],"sub_categories":["Text \u0026 Rich Content","文本相关"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flwansbrough%2Freact-native-markdown","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flwansbrough%2Freact-native-markdown","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flwansbrough%2Freact-native-markdown/lists"}