Sometimes you need to write AsciiDoc within a table, but the standard is that most AsciiDoc formattings don’t work inside a table, onyl the basic syntax:
Col1 |
Col2 |
Basic fomatting like bold works |
advanced formatting like * bullet * lists do not work out of the box |
The solution is to tell AsciiDoc that you need the AsciiDoc formatting. There are two ways to do this.
Just add the chracter a
in front of the |
pipe symbol for the cell and AsciiDoctor will render the cell as AsciiDoc
Col1 |
Col2 |
Basic fomatting like bold works |
advanced formatting like
now work |
You can also configure your columns.
Put a [cols="a,a"]
in front of your table and both columns will be rendered as AsciiDoc
Col1 |
Col2 |
Basic fomatting like bold works |
advanced formatting like
now work |
even complex formattings like source code highlighting works this way |
5.times {
println it
} |