node package manager
Orgs are free. Discover, share, and reuse code in your team. Create a free org »

markdown-tags

markdown-tags

NPM version Build Status Coveralls Status Dependency Status

get tags from markdown article

Install

npm install --save markdown-tags

Usage

import markdownTags from 'markdown-tags';
 
const input = `
# Title
 
_November 5, 2015_
 
#nodejs, #markdown, #qwe-asd`;
 
markdownTags(input).tags; // ['nodejs', 'markdown', 'qwe-asd'] 
markdownTags(input).md;   // '#nodejs, #markdown, #qwe-asd' 
markdownTags();           // undefined ¯\_(ツ)_/¯ 

API

markdownTags(input)

input

Required
Type: String

Markdown string.

Related

License

MIT © Vladimir Starkov