diff --git a/index.d.ts b/index.d.ts index ee6fb56..52b44bf 100644 --- a/index.d.ts +++ b/index.d.ts @@ -1,5 +1,5 @@ declare module 'unique-objects' { - type Obj = Record; + type ObjectType = Record; - export default function (arrayInput: Obj[], keys: (keyof Obj)[]): Obj[]; + export default function (arrayInput: ObjectType[], keys: Array): ObjectType[]; } diff --git a/index.js b/index.js index 3870235..fb1c75c 100644 --- a/index.js +++ b/index.js @@ -1,8 +1,6 @@ function uniqueObjects(arrayInput = [], keys = []) { if (!Array.isArray(arrayInput)) { - throw new TypeError( - `Expected an array for arrayInput, got ${typeof arrayInput}`, - ); + throw new TypeError(`Expected an array for arrayInput, got ${typeof arrayInput}`); } if (!Array.isArray(keys)) { diff --git a/package.json b/package.json index e4ee34b..3d7268c 100644 --- a/package.json +++ b/package.json @@ -45,7 +45,9 @@ "xo": "0.61.1" }, "type": "module", - "eslintIgnore": [ - "index.d.ts" - ] + "xo": { + "ignores": [ + "*.d.ts" + ] + } }