Skip to content

Commit 4b6a3d3

Browse files
authored
Update README.md
Update more guide for $slide and $skip
1 parent 75c2e7e commit 4b6a3d3

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -885,7 +885,8 @@ DB::collection('users')->where('name', 'John')
885885
You can apply projections to your queries using the `project` method.
886886

887887
```php
888-
DB::collection('items')->project(['tags' => array('$slice' => 1)])->get();
888+
DB::collection('items')->project(['tags' => ['$slice' => 1]])->get();
889+
DB::collection('items')->project(['tags' => ['$slice' => [3, 7]]])->get();
889890
```
890891

891892
**Projections with Pagination**

0 commit comments

Comments
 (0)