Socket
Socket
Sign inDemoInstall

md-title

Package Overview
Dependencies
57
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    md-title

get title from markdown article


Version published
Weekly downloads
4
Maintainers
1
Install size
826 kB
Created
Weekly downloads
 

Readme

Source

md-title

NPM version Build Status Coveralls Status Dependency Status

get title from markdown article

Install

npm install --save md-title

Usage

import getTitle from 'md-title';

const input = `
# awesome *heading*

# second heading

paragragh`;

getTitle(input).text; // awesome heading
getTitle(input).html; // <h1>awesome <em>heading</em></h1>
getTitle(input).node; // mdast node, see remark API
getTitle('');         // undefined

API

getTitle(input)

input

Required
Type: String

Markdown string.

  • md-article - extract data from your markdown article
    • md-content - get content 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