Sublime Forum

Help with wrapping multiple lines with tag

#1

Hi,
Currently I have a macro set to wrap multiple lines with a

  • and tag. Here’s an example:

    This:

    item 1
    item 2
    item 3
    item 4

    Turns to this with the macro:

    <li><a href="#" title="item 1">item 1</a></li>
    <li><a href="#" title="item 2">item 2</a></li>
    <li><a href="#" title="item 3">item 3</a></li>
    <li><a href="#" title="item 4">item 4</a></li>

    What I want to do is also add a

      before and after the block of text in a new line… so something like this:
    <ul>
    	<li><a href="#" title="item 1">item 1</a></li>
    	<li><a href="#" title="item 2">item 2</a></li>
    	<li><a href="#" title="item 3">item 3</a></li>
    	<li><a href="#" title="item 4">item 4</a></li>
    </ul>

    I can wrap the multiple lines with a tag, but prefer it NOT to look like this:

    <ul><li><a href="#" title="item 1">item 1</a></li>
    <li><a href="#" title="item 2">item 2</a></li>
    <li><a href="#" title="item 3">item 3</a></li>
    <li><a href="#" title="item 4">item 4</a></li></ul>

    Any ideas?

  • 0 Likes

    #2

    I would like too!
    would make much more sense…

    0 Likes