diff --git a/CHANGELOG.md b/CHANGELOG.md index 68e801a..b2d76c1 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,7 +1,7 @@ ## Changelog -### [v2.3.3](https://github.com/panates/jsopen-objects/compare/v2.3.2...v2.3.3) - +### [v2.3.4](https://github.com/panates/jsopen-objects/compare/v2.3.3...v2.3.4) - -#### 📖 Documentation Changes +#### 🛠 Refactoring and Updates -- docs: add TSDoc to every exported function @Eray Hanoğlu +- refactor: refine `isPlainObject` to improve type safety with `Record<string, any>` @Eray Hanoğlu diff --git a/package-lock.json b/package-lock.json index 918c223..b2766a2 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "@jsopen/objects", - "version": "2.3.3", + "version": "2.3.4", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "@jsopen/objects", - "version": "2.3.3", + "version": "2.3.4", "license": "MIT", "dependencies": { "tslib": "^2.8.1" diff --git a/package.json b/package.json index e3e2804..a4b420c 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "@jsopen/objects", "description": "Helper utilities for working with JavaScript objects and arrays", - "version": "2.3.3", + "version": "2.3.4", "author": "Panates", "license": "MIT", "private": true, @@ -60,7 +60,10 @@ "./package.json": "./package.json" }, "contributors": [ - "Eray Hanoglu " + "Eray Hanoglu ", + "Ilker Gurelli ", + "Onur Tokel ", + "Bircan Yuruk " ], "repository": { "type": "git", diff --git a/src/is-object.ts b/src/is-object.ts index 08ad17c..73a1da1 100644 --- a/src/is-object.ts +++ b/src/is-object.ts @@ -34,7 +34,7 @@ export function isObject(v: any): boolean { * isPlainObject(new (class {})()); // false * isPlainObject([]); // false */ -export function isPlainObject(obj: any): boolean { +export function isPlainObject(obj: any): obj is Record { if ( obj && typeof obj === 'object' &&