[kramdown-users] Table syntax and implementation

Eric Sunshine sunshine at sunshineco.com
Sun Jan 17 08:16:37 EST 2010


Wouldn't it be simplest just to use the single straight-forward rule 
that any rows before the first separator are headers? In other words, 
this table has a header:

   | header1 | header2 |
   |-
   | data1 | data2 |

whereas, this one does not:

   |-
   | data1 | data2 |

(Another way to look at the above table is that it has a null header 
because no lines are present before the first separator line.)

-- ES


On 1/17/2010 5:51 AM, Thomas Leitner wrote:
> On Sat, 16 Jan 2010 18:57:22 +0700, Shawn Van Ittersum wrote:
>> So:
>>
>> |-     separator line
>> |-|    header separator line
>> |--||  separator line
>> |-:|-| header separator line
>>
>> Am I the only one that finds this confusing?
>>
>> Can we please just have one kind of separator line?
>
> I think it would be sufficient to make header separator lines a subset
> of separator lines by allowing a separator line to start with a pipe
> and then any of dash|pipe|plus|space|colon.
>
> Additionally, I would define the header separator line as the first
> encountered separator line (before a footer separator line, naturally)
> and this first separator line can be specially structured to support
> aligning columns (i.e. the current syntax for header separator lines is
> used for determining column alignments).
>
> Would this be less confusing? Comments/suggestions?
>
> -- Thomas
> _______________________________________________
> kramdown-users mailing list
> kramdown-users at rubyforge.org
> http://rubyforge.org/mailman/listinfo/kramdown-users
>


More information about the kramdown-users mailing list