comparingBy property
(dynamic Function(T value)?)
comparingBy
final
The default comparation for obtain selected value uses the ==
operator.
But when working with objects, this method don't will work properly.
Using this function, it's possible set how the comparation supose to be.
Example of usage:
TypeSelector(
comparingBy: (obj) => obj.id,
// other properties
);
Implementation
final dynamic Function(T value)? comparingBy;