You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/syntax/quick-ref.md
+29-60
Original file line number
Diff line number
Diff line change
@@ -111,39 +111,9 @@ A default anchor is automatically created for each [heading](#headings), in the
111
111
112
112
## Applies to
113
113
114
-
Tags that identify technical contexts: the feature base (stack/serverless), deployments, and project types that a piece of content "applies to." Use `applies_to` tags to help users determine whether content is right for their deployments and configuration. For more guidance, see
115
-
[](../versions/content-patterns.md) and the [full syntax guide](applies.md).
114
+
Tags that identify technical contexts: the feature base (stack/serverless), deployments, and project types that a piece of content "applies to." Use `applies_to` tags to help users determine whether content is right for their deployments and configuration. These tags are a [version content pattern](../versions/content-patterns.md) in Elastic Docs v3.
116
115
117
-
:::{tip}
118
-
The `applies_to` tags are scope signals for readers, not comprehensive metadata. If a page contains general information that applies to all contexts, it doesn't need tags.
119
-
:::
120
-
121
-
### Page-level tag
122
-
123
-
:::{dropdown} Syntax
124
-
125
-
This example includes version and release phase facets, which aren't always needed.
126
-
127
-
```yaml
128
-
---
129
-
applies_to:
130
-
stack: 9.0
131
-
deployment:
132
-
ece: preview
133
-
eck: beta 9.0.1
134
-
ess:
135
-
self: 9.0
136
-
serverless:
137
-
elasticsearch:
138
-
observability: deprecated
139
-
security:
140
-
product:
141
-
---
142
-
```
143
-
:::
144
-
145
-
146
-
### Section tag
116
+
**Example: Section tag**
147
117
148
118
:::{dropdown} Syntax
149
119
````markdown
@@ -161,23 +131,25 @@ stack:
161
131
```
162
132
:::
163
133
164
-
### Inline tag
134
+
For full syntax and more examples, see [](applies.md).
165
135
166
-
For details on inline tags, see the [full syntax reference](applies.md).
136
+
<!--
137
+
:::{tip}
138
+
The `applies_to` tags are scope signals for readers, not comprehensive metadata. If a page contains general information that applies to all contexts, it doesn't need tags.
139
+
:::
140
+
-->
141
+
142
+
% TODO restore details when guidance has settled
167
143
168
144
**DOs**<br>
169
-
✅ Define a set of page-level `applies_to`tags in a front matter block<br>
170
-
✅ Add `{applies_to}` after a heading to indicate that section's contexts<br>
171
-
✅ Indicate versions (`major.minor` with an optional `[.patch]`) and release phases like `beta`
145
+
✅ Define a set of [page-level tags](applies.md#page-annotations) in a front matter block<br>
146
+
✅ Add section-level tags in an `{applies_to}`[directive](applies.md#sections)after a heading<br>
147
+
✅ Indicate versions (`major.minor` with an optional `[.patch]`) and release phases like `beta`
172
148
173
149
**DON'Ts**<br>
174
-
❌ Add `applies_to` tags to general, broadly applicable content<br>
175
-
❌ Use `applies_to` tags as metadata or to represent "aboutness"<br>
176
150
❌ Include `applies_to` tags in admonitions<br>
177
-
❌ Use `Coming (x.x.x)` tags, except in special cases (don't pre-announce features)<br>
178
-
179
-
180
-
[More details: Applies to →](applies.md)
151
+
❌ Add `applies_to` tags to general, broadly applicable content<br>
152
+
❌ Use `Coming (x.x.x)` tags, except in special cases (don't pre-announce features)
181
153
<br>
182
154
<br>
183
155
@@ -227,7 +199,7 @@ To explicitly create a code callout, add a number marker in angle brackets (`<1>
227
199
228
200
:::{dropdown} Syntax
229
201
230
-
```markdown callouts=false
202
+
````markdown callouts=false
231
203
```json
232
204
{
233
205
"match": {
@@ -236,6 +208,7 @@ To explicitly create a code callout, add a number marker in angle brackets (`<1>
236
208
}
237
209
```
238
210
1. Searches the `message` field for the phrase "search text"
211
+
````
239
212
:::
240
213
241
214
:::{dropdown} Output
@@ -255,31 +228,31 @@ Add comments with `//` or `#` to magically create callouts.
255
228
256
229
:::{dropdown} Syntax
257
230
````markdown callouts=false
258
-
```json
259
-
{
260
-
"match": {
261
-
"message": "search text" // Searches the message field
262
-
}
263
-
}
264
-
:::
265
-
266
-
:::{dropdown} Output
267
-
```markdown
268
231
```json
269
232
{
270
233
"match": {
271
234
"message": "search text" // Searches the message field
272
235
}
273
236
}
274
237
```
275
-
```
238
+
````
239
+
:::
276
240
241
+
:::{dropdown} Output
242
+
243
+
```json
244
+
{
245
+
"match": {
246
+
"message": "search text" // Searches the message field
247
+
}
248
+
}
249
+
```
277
250
:::
278
251
279
252
**DOs**<br>
280
253
✅ Keep callout text short and specific<br>
281
254
✅ Use only one type of callout per code block (don't mix [explicit](#explicit-callout) and [magic](#magic-callout))<br>
282
-
✅ For explicit callouts, make sure you have a corresponding list item for each callout marker in the code.
255
+
✅ Make sure there's a corresponding list item for each explicit callout marker in a code block
283
256
284
257
**DON'Ts**<br>
285
258
❌ Overuse callouts -- they can impede readability<br>
@@ -696,7 +669,3 @@ Standard table layout for structured data. Automatically scrolls horizontally if
696
669
❌ Use a table solely for position or spacing purposes<br>
0 commit comments