The key to remove the duplicated values from
Optionalvalue: (value: any, index: number, obj: any[]) => anyThe value to remove
Optionaloptions: methodOptionsThe options to use
A promise if the driver is async, otherwise a boolean
const db = new GoodDB(new JSONDriver({
path: './database.json'
}));
db.distinct('key', 'value');
const db = new GoodDB(new MongoDBDriver({
uri: "..."
}));
await db.connect();
await db.distinct('key', 'value');
Remove all values duplicated in a key (array)