Skip to content

Commit f4c6f53

Browse files
authored
[DOCS] Update snippets in API Reference template (#1700)
elastic/elasticsearch#46180 added support for `[source,console]` and `[source,console-result]`, replacing several older 'magic comments' for snippets. This updates the API Reference template for the new code block attributes.
1 parent 13431eb commit f4c6f53

File tree

1 file changed

+3
-6
lines changed

1 file changed

+3
-6
lines changed

shared/api-ref-ex.asciidoc

+3-6
Original file line numberDiff line numberDiff line change
@@ -13,11 +13,10 @@ While optional, we recommend including the example request when possible.
1313

1414
Creates a cool thing.
1515

16-
[source,js]
16+
[source,console]
1717
--------------------------------------------------
1818
PUT twitter
1919
--------------------------------------------------
20-
// CONSOLE
2120

2221
////
2322
***********************************************************
@@ -153,7 +152,7 @@ Optional additional examples.
153152
DO NOT repeat the basic example used earlier.
154153
155154
156-
[source,js]
155+
[source,console]
157156
----
158157
PUT /follower_index/_ccr/follow?wait_for_active_shards=1
159158
{
@@ -171,18 +170,16 @@ PUT /follower_index/_ccr/follow?wait_for_active_shards=1
171170
"read_poll_timeout" : "30s"
172171
}
173172
----
174-
// CONSOLE
175173
// TEST[setup:remote_cluster_and_leader_index]
176174
177175
The API returns the following result:
178176
179-
[source,js]
177+
[source,console-result]
180178
----
181179
{
182180
"follow_index_created" : true,
183181
"follow_index_shards_acked" : true,
184182
"index_following_started" : true
185183
}
186184
----
187-
// TESTRESPONSE
188185
////

0 commit comments

Comments
 (0)