✪ Image
Run Markdown Image

Script key: Run Markdown Image

Posted by crispy_bacon_

Install

Details

Label ✪ Image
Voice Over Run Markdown Image
Script
// Create Markdown link

var sel = getSelectedText();
var selRange = getSelectedRange();

if (!sel || sel.length == 0) {
  setSelectedText("![ ](   )");
  setSelectedRange(selRange[0]+1,0);
}
else {
  setSelectedText("["+sel+"]()");
  setSelectedRange(selRange[0]+selRange[1]+3,0);
}

Advanced

Keyboard shortcut None
Hide key Yes

Discussion

comments powered by Disqus