typs.js
// checks if obj satisfies one or more type signatures
checks if obj satisfies one or more type signatures
checks if obj satisfies one or more type signatures
matchesAny (types) {
		if (typs(types).array().doesntCheck()) {
			throw new Error('typs().matchesAny() expectes an array of types as its first parameter');
		}
		if (typs.apply(typs, types).type().doesntCheck()) {
			throw new Error('typs().matchesAny() expectes an array of types as its first parameter');
		}
		return this.add((obj) => {
			return types.some((t) => typs(obj).is(t));
		});
	}
matchesAny ( types ) { if ( typs ( types ) . array ( ) . doesntCheck ( ) ) { throw new Error ( 'typs().matchesAny() expectes an array of types as its first parameter' ) ; } if ( typs . apply ( typs , types ) . type ( ) . doesntCheck ( ) ) { throw new Error ( 'typs().matchesAny() expectes an array of types as its first parameter' ) ; } return this . add ( ( obj ) => { return types . some ( ( t ) => typs ( obj ) . is ( t ) ) ; } ) ; }
checks if obj satisfies one or more type signatures
checks if obj satisfies one or more type signatures