wallet-core/node_modules/marked/README.md

54 lines
1.0 KiB
Markdown
Raw Normal View History

2018-09-20 02:56:13 +02:00
# Marked
2017-05-24 15:10:37 +02:00
2018-09-20 02:56:13 +02:00
Marked is
2017-05-24 15:10:37 +02:00
2018-09-20 02:56:13 +02:00
1. built for speed.
2. a low-level markdown compiler that allows frequent parsing of large chunks of markdown without caching or blocking for long periods of time.
3. light-weight while implementing all markdown features from the supported flavors & specifications.
4. available as a command line interface (CLI) and running in client- or server-side JavaScript projects.
2017-05-24 15:10:37 +02:00
2018-09-20 02:56:13 +02:00
## Installation
2017-05-24 15:10:37 +02:00
2018-09-20 02:56:13 +02:00
**CLI:** `npm install -g marked`
2017-05-24 15:10:37 +02:00
2018-09-20 02:56:13 +02:00
**In-browser:** `npm install marked --save`
2017-05-24 15:10:37 +02:00
2018-09-20 02:56:13 +02:00
## Usage
2017-05-24 15:10:37 +02:00
2018-09-20 02:56:13 +02:00
**CLI**
2017-05-24 15:10:37 +02:00
2018-09-20 02:56:13 +02:00
``` bash
$ marked -o hello.html
hello world
^D
$ cat hello.html
<p>hello world</p>
2017-05-24 15:10:37 +02:00
```
2018-09-20 02:56:13 +02:00
**Browser**
2017-05-24 15:10:37 +02:00
```html
<!doctype html>
<html>
<head>
<meta charset="utf-8"/>
<title>Marked in the browser</title>
2018-09-20 02:56:13 +02:00
<script src="https://cdn.jsdelivr.net/npm/marked/marked.min.js"></script>
2017-05-24 15:10:37 +02:00
</head>
<body>
<div id="content"></div>
<script>
document.getElementById('content').innerHTML =
2018-09-20 02:56:13 +02:00
marked('# Marked in the browser\n\nRendered by **marked**.');
2017-05-24 15:10:37 +02:00
</script>
</body>
</html>
```
## License
2018-09-20 02:56:13 +02:00
Copyright (c) 2011-2018, Christopher Jeffrey. (MIT License)
2017-05-24 15:10:37 +02:00