Skip to content

Commit dfde4ee

Browse files
ethanpalmstreats
andauthored
Add {% rowheaders %} guidelines to content markup reference (#35689)
Co-authored-by: Annie Streater <12902836+streats@users.noreply.github.com>
1 parent 07b18e5 commit dfde4ee

File tree

1 file changed

+27
-0
lines changed

1 file changed

+27
-0
lines changed

contributing/content-markup-reference.md

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -248,6 +248,33 @@ Reusable strings (commonly called content references or conrefs) contain content
248248

249249
For longer strings, we use reusables, and for shorter strings, we use variables. For more information about reusables, see the [reusables README](../data/reusables/README.md). For more information about variables, see the [variables README](../data/variables/README.md).
250250

251+
## Table row headers
252+
253+
If you create a table where the first column contains headers for the table rows, wrap your table in the Liquid tag `{% rowheaders %} {% endrowheaders %}`. For more information, see "[Use proper markup for row and column headers](./content-style-guide.md#use-proper-markup-for-row-and-column-headers)" in the style guide.
254+
255+
### Example table with row headers
256+
257+
```
258+
{% rowheaders %}
259+
260+
| | Mona | Tom | Hobbes |
261+
|---|---|---|---|
262+
|Type of cat| Octo | Tuxedo | Tiger |
263+
|Likes to swim in the ocean| Yes | No | No |
264+
265+
{% endrowheaders %}
266+
```
267+
268+
### Example table without row headers
269+
270+
```
271+
| Name | Vocation |
272+
| --- | --- |
273+
| Mona | GitHub mascot |
274+
| Tom | Mouse antagonist |
275+
| Hobbes | Best friend |
276+
```
277+
251278
## Tables with codeblocks
252279

253280
Although using tables to contain block items, such as code blocks, is generally discouraged, occasionally it may be appropriate.

0 commit comments

Comments
 (0)