Skip to content

Commit c6373b4

Browse files
author
Marek Suchánek
committed
Add a snippet template; #13
1 parent c9dbc12 commit c6373b4

File tree

1 file changed

+43
-0
lines changed

1 file changed

+43
-0
lines changed

data/templates/snippet.adoc

Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
////
2+
Base the file name on the snippet title. For example:
3+
* file name: snip-my-snippet-a.adoc
4+
* Title: .My snippet A
5+
6+
A snippet is not a module. Consider storing snippet files in a separate snippets folder.
7+
8+
Indicate the content type in one of the following ways:
9+
Add the prefix snip- or snip_ to the file name.
10+
Add the following attribute before the title:
11+
:_content-type: SNIPPET
12+
////
13+
14+
.{{module_title}}
15+
////
16+
The title is optional in a snippet. Use the block title syntax, such as .My snippet A, rather than a numbered heading, such as = My snippet A.
17+
18+
In the title of snippets, include nouns or noun phrases that are used in the body text. This helps readers and search engines find the information quickly. Do not start the title of snippets with a verb. See also _Wording of headings_ in _The IBM Style Guide_.
19+
20+
Do not specify an ID for the snippet title.
21+
////
22+
23+
{% if examples -%}
24+
A text snippet is a small fragment of text that is stored in an AsciiDoc file. Text snippets contain content that is reused in multiple modules or assemblies, for example:
25+
26+
* A step or series of steps in a procedure
27+
* A disclaimer, for example, for technology preview or beta releases
28+
29+
[NOTE]
30+
--
31+
Additional guidance or advice that improves product configuration, performance, or supportability.
32+
--
33+
34+
[IMPORTANT]
35+
--
36+
Advisory information essential to the completion of a task. Users must not disregard this information.
37+
--
38+
39+
[WARNING]
40+
--
41+
Information about potential system damage, data loss, or a support-related issue if the user disregards this admonition. Explain the problem, cause, and offer a solution that works. If available, offer information to avoid the problem in the future or state where to find more information.
42+
--
43+
{%- endif %}

0 commit comments

Comments
 (0)