Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/mamal72/rtl-md
:pencil: A simple markdown to html converter which knows the direction!
https://github.com/mamal72/rtl-md
markdown persian rtl
Last synced: 3 months ago
JSON representation
:pencil: A simple markdown to html converter which knows the direction!
- Host: GitHub
- URL: https://github.com/mamal72/rtl-md
- Owner: mamal72
- License: mit
- Created: 2015-12-22T03:34:06.000Z (about 9 years ago)
- Default Branch: master
- Last Pushed: 2016-05-30T20:07:35.000Z (over 8 years ago)
- Last Synced: 2024-10-07T03:43:24.958Z (4 months ago)
- Topics: markdown, persian, rtl
- Language: JavaScript
- Homepage:
- Size: 6.84 KB
- Stars: 28
- Watchers: 4
- Forks: 3
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
[![Build Status](https://travis-ci.org/mamal72/rtl-md.svg?branch=master)](https://travis-ci.org/mamal72/rtl-md)
[![npm version](https://badge.fury.io/js/rtl-md.svg)](https://badge.fury.io/js/rtl-md)
# rtl-md
**rtl-md** is a markdown parser with RTL languages detection. This module converts the `Markdown` to `HTML` and fixes the elements direction based on the contents of them. This module made in order to help users publish their RTL markdown contents easily, without having to write boring HTML. Now, I can write and publish my `README.md` files in RTL languages too just like LTR languages!# Installation
```bash
npm install --save rtl-md
```# Usage
```js
import rmd from 'rtl-md';
const md = `# Some Markdown!
## Some english ltr stuff here and then, some rtl maybe.بنی آدم اعضای یکدیگرند
که در آفرینش ز یک گوهرند
[سعدی شیرازی](https://en.wikiquote.org/wiki/Saadi)
`
const html = rmd(md);// The output
/*Some Markdown!
Some english ltr stuff here and then, some rtl maybe.
بنی آدم اعضای یکدیگرند
که در آفرینش ز یک گوهرند
*/
```# Ideas || Issues
Just fill an issue and describe it. I'll check it ASAP!# Contribution
You can fork the repository, improve or fix some part of it and then send the pull requests back if you want to see them here. I really appreciate that. :heart:Remember to lint your code before sending pull requests. Run the Grunt lint task with the following command and fix the lint errors if you get any.
```bash
grunt lint
```