Repository URL to install this package:
|
Version:
1.3.1 ▾
|
// import { curry } from 'chain-able-boost'
// const isEqualLabelValue = curry(2, function isEqualLabelValue(one, two) {
// return one.value === two.value && one.label === two.label
// })
export interface LabelValue<Label = string, Value = any> {
label?: Label
value?: Value
}
export function isEqualLabelValue<
One extends LabelValue = LabelValue,
Two extends LabelValue = LabelValue
>(one: One, two: Two) {
return one.value === two.value && one.label === two.label
}