Вспомогательная функция, ниже понадобится:
function getFilterByCount(arr, filterFn, key) {
const getKey = key instanceof Function ? key : key == null ? n => n : n => n[key];
const count = arr.reduce((acc, n) => acc.set(getKey(n), -~acc.get(getKey(n))), new Map);
return n => !!filterFn(count.get(getKey(n)));
}
Собираем новый массив:
const filterByCount = (...args) => args[0].filter(getFilterByCount(...args));
const newArr = filterByCount(arr, count => count > 1, 'props1');
Удаляем из существующего:
function deleteByCount(arr, filterFn, key) {
let numDeleted = 0;
arr.forEach(function(n, i, a) {
a[i - numDeleted] = n;
numDeleted += this(n);
}, getFilterByCount(arr, filterFn, key));
arr.length -= numDeleted;
}
deleteByCount(arr, count => count < 2, n => n.props1);