- Preparing search index...
- The search index is not available
@nathanpb/kext
- takeUnless<T, R>(receiver: T, predicate: boolean | ((it: T) => it is R) | ((it: T) => boolean)): Exclude<T, R> | undefined
-
Parameters
-
receiver: T
-
predicate: boolean | ((it: T) => it is R) | ((it: T) => boolean)
Returns Exclude<T, R> | undefined
Applies
receivertopredicate, returnsreceiverif the givenpredicateresolves intofalse, orundefinedotherwise.If
predicateis a boolean, returnsreceivercause falsy orundefinedotherwise.https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/take-unless.html
Returns
receiverifpredicate(or it's evaluation) isfalse.undefinedotherwise.