mirror of
https://github.com/liriliri/eruda.git
synced 2026-03-20 09:38:37 +08:00
chore: small changes
This commit is contained in:
@@ -871,22 +871,6 @@ castPath('a[0].b'); // -> ['a', '0', 'b']
|
||||
castPath('a.b.c', {'a.b.c': true}); // -> ['a.b.c']
|
||||
```
|
||||
|
||||
## chunk
|
||||
|
||||
Split array into groups the length of given size.
|
||||
|
||||
|Name |Desc |
|
||||
|------|--------------------|
|
||||
|arr |Array to process |
|
||||
|size=1|Length of each chunk|
|
||||
|return|Chunks of given size|
|
||||
|
||||
```javascript
|
||||
chunk([1, 2, 3, 4], 2); // -> [[1, 2], [3, 4]]
|
||||
chunk([1, 2, 3, 4], 3); // -> [[1, 2, 3], [4]]
|
||||
chunk([1, 2, 3, 4]); // -> [[1], [2], [3], [4]]
|
||||
```
|
||||
|
||||
## clamp
|
||||
|
||||
Clamp number within the inclusive lower and upper bounds.
|
||||
|
||||
Reference in New Issue
Block a user