2018-03-11 17:16:48 -04:00
< ul >
< li >< a href = " #marked " > About</ a ></ li >
2018-03-25 20:46:27 -04:00
< li >< a href = " #demo " > Demo</ a ></ li >
2018-03-22 11:57:04 -05:00
< li >< a href = " #installation " > Installation</ a ></ li >
2018-03-11 17:16:48 -04:00
< li >< a href = " #usage " > Usage</ a ></ li >
< li >< a href = " #specifications " > Supported Markdown specifications</ a ></ li >
< li >< a href = " #security " > Security</ a ></ li >
< li >< a href = " #contributing " > Contributing</ a ></ li >
< li >< a href = " #authors " > Authors</ a ></ li >
< li >< a href = " #license " > License</ a ></ li >
< / ul >
< h2 id = "marked" > Marked< / h2 >
2018-03-22 11:57:04 -05:00
Marked is
2018-03-11 17:16:48 -04:00
1. built for speed.< sup > *</ sup >
2018-04-04 22:43:24 -04:00
2. a low-level markdown compiler for parsing markdown without caching or blocking for long periods of time.< sup > **</ sup >
2018-03-11 17:16:48 -04:00
3. light-weight while implementing all markdown features from the supported flavors & specifications.< sup > ***</ sup >
4. available as a command line interface (CLI) and running in client- or server-side JavaScript projects.
< p > < small > < sup > *< / sup > Still working on metrics for comparative analysis and definition.< / small > < br >
< small > < sup > **< / sup > As few dependencies as possible.< / small > < br >
< small > < sup > ***< / sup > Strict compliance could result in slower processing when running comparative benchmarking.< / small > < / p >
2018-03-25 20:46:27 -04:00
< h2 id = "demo" > Demo< / h2 >
2018-03-26 10:36:47 -05:00
Checkout the [demo page ](./demo/ ) to see marked in action ⛹️
2018-03-25 20:46:27 -04:00
These documentation pages are also rendered using marked 💯
2018-03-11 17:16:48 -04:00
< h2 id = "installation" > Installation< / h2 >
**CLI:** `npm install -g marked`
**In-browser:** `npm install marked --save`
< h2 id = "usage" > Usage< / h2 >
**CLI**
``` bash
$ marked -o hello.html
hello world
^D
$ cat hello.html
< p > hello world< / p >
```
2018-04-01 23:25:53 -05:00
``` bash
$ marked -s "*hello world*"
< p > < em > hello world< / em > < / p >
```
2018-03-11 17:16:48 -04:00
**Browser**
```html
<!doctype html>
< html >
< head >
< meta charset = "utf-8" / >
< title > Marked in the browser< / title >
< / head >
< body >
< div id = "content" > < / div >
2018-03-25 20:36:41 -04:00
< script src = "https://cdn.jsdelivr.net/npm/marked/marked.min.js" > < / script >
2018-03-11 17:16:48 -04:00
< script >
document.getElementById('content').innerHTML =
marked('# Marked in browser\n\nRendered by **marked** .');
< / script >
< / body >
< / html >
```
2018-03-27 14:06:54 -05:00
Marked offers [advanced configurations ](#/USING_ADVANCED.md ) and [extensibility ](#/USING_PRO.md ) as well.
2018-03-11 17:16:48 -04:00
< h2 id = "specifications" > Supported Markdown specifications< / h2 >
We actively support the features of the following [Markdown flavors ](https://github.com/commonmark/CommonMark/wiki/Markdown-Flavors ).
|Flavor |Version |
|:----------------------------------------------------------|:----------|
|The original markdown.pl |-- |
|[CommonMark ](http://spec.commonmark.org/0.28/ ) |0.28 |
|[GitHub Flavored Markdown ](https://github.github.com/gfm/ ) |0.28 |
By supporting the above Markdown flavors, it's possible that Marked can help you use other flavors as well; however, these are not actively supported by the community.
< h2 id = "security" > Security< / h2 >
The only completely secure system is the one that doesn't exist in the first place. Having said that, we take the security of Marked very seriously.
2018-03-27 14:06:54 -05:00
Therefore, please disclose potential security issues by email to the project [committers ](#/AUTHORS.md ) as well as the [listed owners within NPM ](https://docs.npmjs.com/cli/owner ). We will provide an initial assessment of security reports within 48 hours and should apply patches within 2 weeks (also, feel free to contribute a fix for the issue).
2018-03-11 17:16:48 -04:00
< h2 id = "contributing" > Contributing< / h2 >
2018-03-27 14:06:54 -05:00
The marked community enjoys a spirit of collaboration and contribution from all comers. Whether you're just getting started with Markdown, JavaScript, and Marked or you're a veteran with it all figured out, we're here to help each other improve as professionals while helping Marked improve technically. Please see our [contributing documentation ](#/CONTRIBUTING.md ) for more details.
2018-03-11 17:16:48 -04:00
For our Contribution License Agreement, see our [license ](https://github.com/markedjs/marked/blob/master/LICENSE.md ).
< h2 id = "authors" > Authors< / h2 >
2018-03-27 14:06:54 -05:00
For list of credited authors and contributors, please see our [authors page ](#/AUTHORS.md ).
2018-03-11 17:16:48 -04:00
< h2 id = "license" > License< / h2 >
Copyright (c) 2011-2018, Christopher Jeffrey. (MIT License)
See [license ](https://github.com/markedjs/marked/blob/master/LICENSE.md ) for more details.