UNPKG
foop
Version:
beta (5.0.0)
latest (5.0.0)
5.0.0
interfaces that describe their intentions.
github.com/fluents/chain-able
fluents/chain-able
foop
/
src
/
deps
/
fp
/
propSatisfies.js
10 lines
(8 loc)
•
247 B
JavaScript
View Raw
1
2
3
4
5
6
7
8
9
10
const
curry =
require
(
'../fp/curry'
)
const
hasIn =
require
(
'../is/hasIn'
)
// 5.0.0-beta.7
module
.
exports
=
curry
(
3
,
function
_propSatisfies
(
propertyPath, fnIs, obj
) {
return
hasIn
(obj, propertyPath) ?
fnIs
(obj[propertyPath]) :
false
})