Markdown Bullets

By email:

Is there a popClip extension that will add “bullets” in front of a list of items (or dashes, numbers or similar)? I looked in the Extensions area, but didn’t find any.

Here’s a first draft:

// #popclip
// name: Markdown Bullets
// icon: symbol:list.bullet
// language: javascript
popclip.pasteText(popclip.input.text
  .split('\n')
  .map(line => '- ' + line)
  .join('\n'));

(The above block is an extension snippet — select it then click “Install Extension” in PopClip.)

5 Likes

Wow! Thank you for doing this but also for showing how straightforward it is to create new extensions. Just great!

1 Like

Cool. I just pasted your snippet into TextEdit, replaced the hyphen with a bullet, and installed that. Works great!

1 Like

That’s the spirit! :raising_hands: