You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Given a target string and an array of strings, returns the index at which the target string should be inserted into the array to maintain case-insensitive alphabetical order. Example:
```ts
const arr = ['ant', 'bee', 'cat', 'dog'];
const i = getAlphabeticalInsertionIndex('COW', arr); // i = 3
```
*/
export function getAlphabeticalInsertionIndex(target: string, arr: ReadonlyArray<string>): number