Home Download Buy Blog Forum Support

Indentation with html5

Indentation with html5

Postby elainemarley on Wed Oct 03, 2012 7:58 am

I don't know if this might be a bug.

This is the code I have before indentation (html5 doctype):

Code: Select all
   
    <ul>
          <li><a href="../docs/introduction.html">Introduction</a>
          <li><a href="../docs/options.html">Options</a>
          <li><a href="../docs/methods.html">Methods</a>
    </ul>   


And after indentation I get:

Code: Select all
      <ul>
         <li><a href="../docs/introduction.html">Introduction</a>
            <li><a href="../docs/options.html">Options</a>
               <li><a href="../docs/methods.html">Methods</a>
                              </ul>            


It seems ST2 has problems with open tags in html5 syntax
elainemarley
 
Posts: 2
Joined: Wed Oct 03, 2012 7:54 am

Re: Indentation with html5

Postby piksel on Wed Oct 03, 2012 8:16 am

I don't think it's a bug per se, but someone will have to write the parser to allow that type of weird open tags. It works fine for self-closing tags like <link> and <img>.
I couldn't find any good sources about this part of the spec, could you provide me with some links? I don't even know how to regex it.
piksel
 
Posts: 8
Joined: Sat Aug 25, 2012 9:31 am

Re: Indentation with html5

Postby elainemarley on Wed Oct 03, 2012 9:01 am

http://www.w3.org/TR/html-markup/li.html

Tag omission

An li element must have a start tag.

An li element’s end tag may be omitted if the li element is immediately followed by another li element or if there is no more content in the parent element.
elainemarley
 
Posts: 2
Joined: Wed Oct 03, 2012 7:54 am


Return to Technical Support

Who is online

Users browsing this forum: No registered users and 20 guests