import { Predicate } from '../types' ; import { curry3 } from '@typed/functions' ; name export const and = curry3 ( __and ) ; export type And = { < A > ( predicate1 , predicate2 , value ) : boolean ; < A > ( predicate1 , predicate2 ) : Predicate < A > ; < A > ( predicate1 ) : { ( predicate2 , value ) : boolean ; ( predicate2 ) : Predicate < A > ; } ; } ; function __and < A > ( predicate1 , predicate2 , value ) { return predicate1 ( value ) && predicate2 ( value ) ; }