Socket
Socket
Sign inDemoInstall

md-content

Package Overview
Dependencies
58
Maintainers
1
Versions
8
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    md-content

NPM package for getting content from markdown article


Version published
Weekly downloads
20
increased by233.33%
Maintainers
1
Install size
4.93 MB
Created
Weekly downloads
 

Readme

Source

md-content

NPM version Build Status Coveralls Status Dependency Status DevDependency Status

get content from markdown article

Install

npm install --save md-content

Usage

import getContent from 'md-content';

const content_with_header_and_img = `
# header
_20 June 2016_

#tag1 #tag #tag3;

![alt](http://yo.io/)

content1

content2
## header2`;

getContent(content_with_header_and_img).html
// <p><img src="http://yo.io/" alt="alt"></p>
// <p>content1</p>
// <p>content2</p>
// <h2>header2</h2>

getContent(content_with_header_and_img).text
// <img src="http://yo.io/" alt="alt">
// content1
// content2
// header2

API

getContent(input)

input

Required
Type: String

Markdown string.

  • md-article - extract data from your markdown article
    • md-title - get title from markdown article
    • md-date - get date from markdown article
    • md-tags - get tags from markdown article

License

MIT © Aleksandr Filatov

Keywords

FAQs

Last updated on 21 Jul 2016

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