|
| 1 | +# headers |
| 2 | += h1 header |
| 3 | +== h2 header |
| 4 | + |
| 5 | + |
| 6 | +# blocks |
| 7 | +[quote, Somebody, Who is somebody] |
| 8 | +____ |
| 9 | +Quote something |
| 10 | +____ |
| 11 | +// |
| 12 | +NOTE: Some note |
| 13 | +// |
| 14 | +[WARNING] |
| 15 | +==== |
| 16 | +Some warning |
| 17 | +==== |
| 18 | + |
| 19 | +# lists |
| 20 | +.Un-ordered list with a title |
| 21 | +* list item |
| 22 | +** sub-list item |
| 23 | +- hypen as sub-sub-list item |
| 24 | ++ |
| 25 | +that continues at the next line |
| 26 | +- {blank} |
| 27 | ++ |
| 28 | +---- |
| 29 | +complex content of an item |
| 30 | +---- |
| 31 | + |
| 32 | +[%reversed,start=4] |
| 33 | +.Ordered list; reversed, started at 4 |
| 34 | +. ordered list item |
| 35 | +.. ordered list sub-item |
| 36 | +. another list item |
| 37 | + |
| 38 | +# separating adjacent lists (surrounded by blank lines) |
| 39 | +//- |
| 40 | + |
| 41 | +# checklist |
| 42 | +- [*] checked |
| 43 | +- [x] also checked |
| 44 | +- [ ] not checked |
| 45 | + |
| 46 | +Description list item:: definition |
| 47 | +[horizontal] |
| 48 | +Description list item #2:: definition |
| 49 | + |
| 50 | + |
| 51 | +# links |
| 52 | +Automatic link http://example.com or |
| 53 | +http://example.com[link with title and attributes,role=external,window=_blank] |
| 54 | +link:../README.adoc[Relative link to open the README file] |
| 55 | + |
| 56 | + |
| 57 | +# cross reference links |
| 58 | +[[an-anchor]]inline anchor, [#other-anchor]#applied to a phrase# |
| 59 | +Reference to <<an-anchor>> or to <<other-anchor,the other anchor>> |
| 60 | + |
| 61 | + |
| 62 | +# image |
| 63 | +image:image.png[Alt text, title="Inline image"] |
| 64 | + |
| 65 | +.Block image title |
| 66 | +[caption="Figure 1: ",link=http://example.com/image.png] |
| 67 | +image::image.jpg[Alt text, 300, 200] |
| 68 | + |
| 69 | + |
| 70 | +# code |
| 71 | +.... |
| 72 | +literal block |
| 73 | +.... |
| 74 | + |
| 75 | +:variable: 123 |
| 76 | +.Source code title |
| 77 | +[source,asciidoc,subs="+quotes,attributes+",options="nowrap"] |
| 78 | +---- |
| 79 | +:toc: right # <1> |
| 80 | +// with var substitution (attributes+) |
| 81 | +:variable: definition, the value is {variable} |
| 82 | +// with the markup substitution (+quotes) |
| 83 | +// no wrapping long lines (nowrap) |
| 84 | +---- |
| 85 | +<1> Asciidoctor sytax for the table of content |
| 86 | + |
| 87 | +# include source code, stripping indentation |
| 88 | +[source,asciidoc,indent=0] |
| 89 | +---- |
| 90 | +include::doc/document.adoc[lines=5..10] |
| 91 | +---- |
| 92 | + |
| 93 | +# formatting |
| 94 | +*bold*, **un**constrained |
| 95 | +_italic_, __un__constrained |
| 96 | +`monospace`, ``un``constrained |
| 97 | +`[underline]#Underline text#` |
| 98 | +`[overline]#overline text#` |
| 99 | +`[line-through]#strikethrough#` |
| 100 | +`[blue line-through]*bold blue and line-through*.` |
| 101 | + |
| 102 | +# comment |
| 103 | +// text in the comment |
| 104 | + |
| 105 | +# horizontal rules (hr) |
| 106 | +''' |
| 107 | + |
| 108 | +Non-breaking space {nbsp} |
| 109 | +Break at the end of + |
| 110 | +line |
| 111 | + |
| 112 | +# tables |
| 113 | +.Table title |
| 114 | +[caption="Table 2: "] |
| 115 | +|=== |
| 116 | +| Name | Description |
| 117 | +// |
| 118 | +| Asciidoctor |
| 119 | +| Awesome way to write documentation |
| 120 | +// |
| 121 | +2+| This cell spans 2 columns |
| 122 | +// |
| 123 | +.2+| This cell spans 2 rows |
| 124 | +// |
| 125 | +| Line at the side of the spanned rows |
| 126 | +| Another line |
| 127 | +// |
| 128 | +|=== |
0 commit comments