On 12. Oct 2006, at 01:25, Adam Stacoviak wrote:
How could we alter this.
<${1:ul}> ${TM_SELECTED_TEXT/.+/ <li>$0</li>/g} </$1>
...to add a class option to the li tag, but only every other instance of the li tag? Thanks Sune for setting up this snippet, it saves me a ton of time when creating ul/ol lists!!!!
For the middle line, try something like:
${TM_SELECTED_TEXT/(.+)(?:\n(.+))?/ <li class="odd">$1</li>(?2:\n <li>$2</li>)/g}