Skip to content

Commit 6f63baa

Browse files
committed
Documentation
1 parent 29ddcce commit 6f63baa

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

docs/reference/code-blocks.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -215,14 +215,18 @@ import tensorflow as tf
215215
Annotations offer a comfortable and friendly way to attach explanations to
216216
arbitrary sections of code blocks by adding simple markers within block/inline
217217
comments that refer to items of a list following the code block, i.e. `(1)`,
218-
`(2)`, etc. Material for MkDocs removes the list from the flow of the document,
218+
`(2)`, etc. Material for MkDocs detaches the list from the flow of the document,
219219
injects the content of each list item into a tooltip, and links each list marker
220220
to the corresponding tooltip.
221221

222222
In order to opt-in to annotation support, a slightly different syntax is
223223
required – just add the respective [language short code][17] and the `.annotate`
224224
class, after the three backticks.
225225

226+
Note that annotations can be __placed anywhere__ in a code block where a comment
227+
for the language can be placed, which for JavaScript is `// (1)` and
228+
`/* (2) */`, for Yaml `# (3)`, etc.
229+
226230
_Example_:
227231

228232
```` markdown

0 commit comments

Comments
 (0)