Socket
Socket
Sign inDemoInstall

cli-marked

Package Overview
Dependencies
52
Maintainers
1
Versions
35
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    cli-marked

A custom render for marked to output to the Terminal


Version published
Maintainers
1
Created

Readme

Source

Welcome to cli-marked

Version Documentation Maintenance License: GPL-3.0 Downloads

Custom Renderer for marked allowing for printing Markdown to the Terminal. Supports pretty tables and syntax highlighting

Could for instance be used to print usage information.

Install

npm i -g cli-marked

Example

md demo.md

This will produce the following:

Screenshot of marked-terminal

Screenshot of marked-terminal

Usage as module

npm i cli-marked
const marked = require('marked');
const TerminalRenderer = require('cli-marked');

marked.setOptions({
  renderer: new TerminalRenderer({}),
  mangle: false,
  emoji: true,
  breaks: false,
  gfm: true,
  smartypants: false,
});

const markdown = `
# Hello World

---

* One
* Two
* Three
`

console.log(marked(markdown));

Run tests

npm run test

Author

👤Grigorii Horos

  • Github: @horosgrisa

Contributing

Contributions, issues and feature requests are welcome!

Feel free to check issues page.

Show your support

Give a ⭐️ if this project helped you!

License

Copyright © 2019 Grigorii Horos.

This project is GPL-3.0-or-later licensed.

Keywords

FAQs

Last updated on 06 Nov 2019

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc