1

Topic: Write a small plugin for pick values from list and insert in textarea

Lets said I have this piece of drop down list:

<ul>
  <li>{{key1}}</li>
  <li>{{key2}}</li>
  <li>{{key3}}</li>
</ul>

I want to write a plugin or something that allow me:

  • Display that list as a button dropdown on the toolbar

  • When I choose any of the items from that dropdown insert the value/content at the same place where cursor is under the textarea

Can any give me some ideas? Some docs to read on? I am complete new to this