isStringIncludes()
isStringIncludes()
isStringIncludes()
Checks if any
value is a string
type or an instance of String
(by using isString()
) that includes all of the specified words/sentences.
Generic type variables
Type
extends
AnyString
=
string
Type
extends
AnyString
=
string
A generic type variable Type
constrained by generic type AnyString
indicates the string
type of the given value
via the return type.
Payload
extends
object
=
object
Payload
extends
object
=
object
Parameters
value: any
value: any
The value of any
type to check against the string
that contains words/sentences from a given includes
.
includes: string[]
includes: string[]
An Array
of string
as words/sentences to be case-sensitive searched for within the given value
.
callback: ResultCallback<any, { includes: typeof includes } & Payload>
callback: ResultCallback<any, { includes: typeof includes } & Payload>
payload?: Payload
payload?: Payload
Return type
value is Type
value is Type
The return type is a boolean
as the result of its statement indicating the value
is a generic type variable Type
by default equal to the string
.
Returns
The return value is a boolean
indicating whether the provided value
is a string
type or an instance of String
that includes all of the specified words/sentences.
Example usage
Last updated
Was this helpful?