Module

x/lodash_es/src/util.js>conforms

lodash for deno use
Latest
function conforms
import { conforms } from "https://dotland.deno.dev/x/lodash_es@v0.0.2/src/util.js";

Creates a function that invokes the predicate properties of source with the corresponding property values of a given object, returning true if all predicates return truthy, else false.

Note: The created function is equivalent to _.conformsTo with source partially applied.

Examples

var objects = [ { 'a': 2, 'b': 1 }, { 'a': 1, 'b': 2 } ];

_.filter(objects, _.conforms({ 'b': function(n) { return n > 1; } })); // => [{ 'a': 1, 'b': 2 }]

Parameters

source

The object of property predicates to conform to.