content/flux/v0/stdlib/regexp/findstringindex.md
regexp.findStringIndex() returns a two-element array of integers that represent the
beginning and ending indexes of the first regular expression match in a string.
(r: regexp, v: string) => [int]
{{% caption %}} For more information, see Function type signatures. {{% /caption %}}
({{< req >}})
Regular expression used to search v.
({{< req >}}) String value to search.
import "regexp"
regexp.findStringIndex(r: /ab?/, v: "tablet")// Returns [1, 3]