get image from markdown article
npm install --save get-md-image
import getImage from 'get-md-image';
const input = `
# title
description ![meow](http://placekitten.com/g/300)`;
getImage(input).alt; // meow
getImage(input).src; // http://placekitten.com/g/300
getImage(input).html; // <img src="http://placekitten.com/g/300" alt="meow" />
getImage(''); // undefined ¯\_(ツ)_/¯
Required
Type: String
Markdown string.
MIT © Vladimir Starkov