add support for only checking attributes in isActive

This commit is contained in:
Philipp Kühn
2020-11-30 00:04:30 +01:00
parent 9a18cce546
commit ec56158739
7 changed files with 76 additions and 25 deletions

View File

@@ -0,0 +1,6 @@
export default function objectIncludes(object1: { [key: string ]: any }, object2: { [key: string ]: any }): boolean {
return !!Object
.keys(object2)
.filter(key => object2[key] === object1[key])
.length
}