@nyaomaru/divider 1.8.8 → 1.8.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs +4 -1
- package/dist/index.js +4 -1
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -43,8 +43,11 @@ function isString(arg) {
|
|
|
43
43
|
function isNumber(arg) {
|
|
44
44
|
return typeof arg === "number";
|
|
45
45
|
}
|
|
46
|
+
function isObject(arg) {
|
|
47
|
+
return typeof arg === "object" && arg !== null;
|
|
48
|
+
}
|
|
46
49
|
function isOptions(value) {
|
|
47
|
-
if (
|
|
50
|
+
if (!isObject(value)) return false;
|
|
48
51
|
const options = value;
|
|
49
52
|
return dividerOptionKeys.some((key) => Object.hasOwn(options, key));
|
|
50
53
|
}
|
package/dist/index.js
CHANGED
|
@@ -13,8 +13,11 @@ function isString(arg) {
|
|
|
13
13
|
function isNumber(arg) {
|
|
14
14
|
return typeof arg === "number";
|
|
15
15
|
}
|
|
16
|
+
function isObject(arg) {
|
|
17
|
+
return typeof arg === "object" && arg !== null;
|
|
18
|
+
}
|
|
16
19
|
function isOptions(value) {
|
|
17
|
-
if (
|
|
20
|
+
if (!isObject(value)) return false;
|
|
18
21
|
const options = value;
|
|
19
22
|
return dividerOptionKeys.some((key) => Object.hasOwn(options, key));
|
|
20
23
|
}
|