If you know how to fix the issue, make a pull request instead.
I have a couple of different classes that use the same semantic property name. Prior to the 4.14.78 release, I could do the following:
class A {
constructor(myName) {
this.name = myName;
}
}
class B {
constructor(myName, age) {
this.name = myName;
this.age = age;
}
}
let a1 = new A('a1');
let a2 = new A('a2');
let b1 = new B('a1', 30);
let diff = _.differenceBy([a1, a2], [b1], 'name');
// result: [{name: a2}]
Now, the type definition prevents me from doing this because class A and B are not related. It doesn't appear to be a restriction in lodash code itself. Should the type definition be this strict?
If you know how to fix the issue, make a pull request instead.
@types/lodashpackage and had problems.Definitions by:inindex.d.ts) so they can respond.I have a couple of different classes that use the same semantic property name. Prior to the 4.14.78 release, I could do the following:
Now, the type definition prevents me from doing this because class A and B are not related. It doesn't appear to be a restriction in lodash code itself. Should the type definition be this strict?