@vkontakte/videoplayer-shared 1.0.58-dev.bc8d7a0b.0 → 1.0.58-dev.eda65eb1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,10 @@
1
+ /**
2
+ * Performs binary search on a sorted array using a comparison function
3
+ * @param sortedArray - The sorted array to search in
4
+ * @param compareFn - Function that returns:
5
+ * - 0 if the current element matches the target
6
+ * - negative if the current element is less than the target
7
+ * - positive if the current element is greater than the target
8
+ * @returns The index of the matching element if found, otherwise -1
9
+ */
10
+ export declare const binarySearch: <T>(sortedArray: T[], compareFn: (element: T) => number) => number;
@@ -22,3 +22,4 @@ export { flattenObject } from './flattenObject';
22
22
  export { clearVideoElement } from './clearVideoElement';
23
23
  export * from './isValidURL';
24
24
  export * from './createURL';
25
+ export { binarySearch } from './binarySearch';