Skip to content

Commit 22249d1

Browse files
committed
docs: remove dotted index selector examples [skip ci]
1 parent 36659d4 commit 22249d1

File tree

2 files changed

+2
-10
lines changed

2 files changed

+2
-10
lines changed

README.md

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -157,18 +157,14 @@ $.categories[0][name]
157157
$.categories[0]['name']
158158
```
159159

160-
### Array indices (`.0`, `[0]` or `[-1]`)
160+
### Array indices (`[0]` or `[-1]`)
161161

162162
Select an item from an array by its index. Indices are zero-based and enclosed in brackets. If the index is negative, items are selected from the end of the array. Considering example data from the top of this page, the following examples are equivalent.
163163

164164
```text
165165
$.categories[0]
166166
```
167167

168-
```text
169-
$.categories.0
170-
```
171-
172168
```text
173169
$.categories[-1]
174170
```

docs/syntax.md

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -42,18 +42,14 @@ $.categories[0][name]
4242
$.categories[0]['name']
4343
```
4444

45-
### Array indices (`.0`, `[0]` or `[-1]`)
45+
### Array indices (`[0]` or `[-1]`)
4646

4747
Select an item from an array by its index. Indices are zero-based and enclosed in brackets. If the index is negative, items are selected from the end of the array. Considering example data from the top of this page, the following examples are equivalent.
4848

4949
```text
5050
$.categories[0]
5151
```
5252

53-
```text
54-
$.categories.0
55-
```
56-
5753
```text
5854
$.categories[-1]
5955
```

0 commit comments

Comments
 (0)