mirror of
https://github.com/denoland/std.git
synced 2024-11-22 04:59:05 +00:00
docs(bytes): update API doc of lastIndexOfNeedle (#4665)
This commit is contained in:
parent
8c9e96c402
commit
1cfd39cf7c
@ -10,7 +10,7 @@
|
||||
* @param source Source array to check.
|
||||
* @param needle Needle array to check for.
|
||||
* @param start Start index in the source array to begin the search. Defaults to
|
||||
* the end of the array.
|
||||
* `source.length - 1`.
|
||||
* @returns Index of the last occurrence of the needle array in the source
|
||||
* array, or -1 if it is not present.
|
||||
*
|
||||
@ -34,7 +34,7 @@
|
||||
* const needle = new Uint8Array([1, 2]);
|
||||
*
|
||||
* lastIndexOfNeedle(source, needle, 2); // 1
|
||||
* lastIndexOfNeedle(source, needle, 6); // 3
|
||||
* lastIndexOfNeedle(source, needle, 6); // 5
|
||||
* ```
|
||||
* Defining a start index will begin the search at the specified index in the
|
||||
* source array.
|
||||
|
Loading…
Reference in New Issue
Block a user