Finds first index of a subsequence.
[:package:](https://www.npmjs.com/package/@extra-array/search-subsequence)
[:smiley_cat:](https://github.com/orgs/nodef/packages?repo_name=extra-array)
[:running:](https://npm.runkit.com/@extra-array/search-subsequence)
[:vhs:](https://asciinema.org/a/339819)
[:moon:](https://www.npmjs.com/package/@extra-array/search-subsequence.min)
[:scroll:](https://unpkg.com/@extra-array/search-subsequence/)
[:newspaper:](https://nodef.github.io/extra-array/)
[:blue_book:](https://github.com/nodef/extra-array/wiki/)

> Similar: [subsequence], [subsequences], [hasSubsequence], [searchSubsequence].<br>
> Similar: [hasValue], [hasPrefix], [hasInfix], [hasSuffix], [hasSubsequence], [hasPermutation].

> This is part of package [extra-array].

[extra-array]: https://www.npmjs.com/package/extra-array

<br>

```javascript
array.searchSubsequence(x, y, [fc], [fm]);
// x:  an array
// y:  subsequence?
// fc: compare function (a, b)
// fm: map function (v, i, x)
```

```javascript
const array = require("extra-array");

var x = [1, 2, 3, 4];
array.searchSubsequence(x, [2, 4]);
// 1

array.searchSubsequence(x, [-2, -4]);
// -1

array.searchSubsequence(x, [-2, -4], (a, b) => Math.abs(a) - Math.abs(b));
// 1

array.searchSubsequence(x, [-2, -4], null, v => Math.abs(v));
// 1
```

<br>
<br>


## References

- [Data.List.isSubsequenceOf: Haskell](https://hackage.haskell.org/package/base-4.12.0.0/docs/Data-List.html#v:isSubsequenceOf)
- [List-Extra.isSubsequenceOf: elm](https://package.elm-lang.org/packages/elm-community/list-extra/7.1.0/List-Extra#isSubsequenceOf)

[subsequence]: https://github.com/nodef/extra-array/wiki/subsequence
[subsequences]: https://github.com/nodef/extra-array/wiki/subsequences
[searchSubsequence]: https://github.com/nodef/extra-array/wiki/searchSubsequence
[hasSubsequence]: https://github.com/nodef/extra-array/wiki/hasSubsequence
[hasValue]: https://github.com/nodef/extra-array/wiki/hasValue
[hasPrefix]: https://github.com/nodef/extra-array/wiki/hasPrefix
[hasInfix]: https://github.com/nodef/extra-array/wiki/hasInfix
[hasSuffix]: https://github.com/nodef/extra-array/wiki/hasSuffix
[hasPermutation]: https://github.com/nodef/extra-array/wiki/hasPermutation
