@alextheman/utility 3.4.0 → 3.4.2
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 +1 -1
- package/dist/index.js +1 -1
- package/package.json +29 -30
package/dist/index.cjs
CHANGED
|
@@ -397,7 +397,7 @@ var omitProperties_default = omitProperties;
|
|
|
397
397
|
//#region src/functions/parsers/parseBoolean.ts
|
|
398
398
|
function parseBoolean(inputString) {
|
|
399
399
|
const normalisedString = inputString.toLowerCase();
|
|
400
|
-
if (
|
|
400
|
+
if (!["true", "false"].includes(normalisedString)) throw new TypeError("INVALID_BOOLEAN_STRING");
|
|
401
401
|
return normalisedString === "true";
|
|
402
402
|
}
|
|
403
403
|
/** @deprecated This function has been renamed to parseBoolean. */
|
package/dist/index.js
CHANGED
|
@@ -368,7 +368,7 @@ var omitProperties_default = omitProperties;
|
|
|
368
368
|
//#region src/functions/parsers/parseBoolean.ts
|
|
369
369
|
function parseBoolean(inputString) {
|
|
370
370
|
const normalisedString = inputString.toLowerCase();
|
|
371
|
-
if (
|
|
371
|
+
if (!["true", "false"].includes(normalisedString)) throw new TypeError("INVALID_BOOLEAN_STRING");
|
|
372
372
|
return normalisedString === "true";
|
|
373
373
|
}
|
|
374
374
|
/** @deprecated This function has been renamed to parseBoolean. */
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@alextheman/utility",
|
|
3
|
-
"version": "3.4.
|
|
3
|
+
"version": "3.4.2",
|
|
4
4
|
"description": "Helpful utility functions",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -15,44 +15,43 @@
|
|
|
15
15
|
"files": [
|
|
16
16
|
"dist"
|
|
17
17
|
],
|
|
18
|
-
"scripts": {
|
|
19
|
-
"build": "tsdown",
|
|
20
|
-
"change-major": "npm version major -m \"Change version number to v%s\"",
|
|
21
|
-
"change-minor": "npm version minor -m \"Change version number to v%s\"",
|
|
22
|
-
"change-patch": "npm version patch -m \"Change version number to v%s\"",
|
|
23
|
-
"create-local-package": "npm run build && rm -f alextheman-utility-*.tgz && npm pack",
|
|
24
|
-
"format": "npm run format-prettier && npm run format-eslint",
|
|
25
|
-
"format-eslint": "eslint --fix --suppress-all \"package.json\" \"src/**/*.ts\" \"tests/**/*.ts\" && rm -f eslint-suppressions.json",
|
|
26
|
-
"format-prettier": "npm run format-prettier-typescript && npm run format-prettier-javascript",
|
|
27
|
-
"format-prettier-javascript": "prettier --write \"./**/*.js\"",
|
|
28
|
-
"format-prettier-typescript": "prettier --write --parser typescript \"./**/*.ts\"",
|
|
29
|
-
"lint": "npm run lint-tsc && npm run lint-eslint && npm run lint-prettier",
|
|
30
|
-
"lint-eslint": "eslint \"package.json\" \"src/**/*.ts\" \"tests/**/*.ts\"",
|
|
31
|
-
"lint-prettier": "npm run lint-prettier-typescript && npm run lint-prettier-javascript",
|
|
32
|
-
"lint-prettier-javascript": "prettier --check \"./**/*.js\"",
|
|
33
|
-
"lint-prettier-typescript": "prettier --check --parser typescript \"./**/*.ts\"",
|
|
34
|
-
"lint-tsc": "tsc --noEmit",
|
|
35
|
-
"prepare": "husky",
|
|
36
|
-
"test": "vitest run",
|
|
37
|
-
"test-watch": "vitest",
|
|
38
|
-
"update-dependencies": "bash -c 'npx npm-check-updates -u \"$@\" && npm install' --",
|
|
39
|
-
"use-live-eslint-plugin": "npm uninstall @alextheman/eslint-plugin && npm install --save-dev @alextheman/eslint-plugin",
|
|
40
|
-
"use-local-eslint-plugin": "npm --prefix ../eslint-plugin run create-local-package && npm uninstall @alextheman/eslint-plugin && npm install --save-dev ../eslint-plugin/alextheman-eslint-plugin-*.tgz"
|
|
41
|
-
},
|
|
42
18
|
"dependencies": {
|
|
43
19
|
"zod": "^4.1.13"
|
|
44
20
|
},
|
|
45
21
|
"devDependencies": {
|
|
46
|
-
"@alextheman/eslint-plugin": "^4.
|
|
22
|
+
"@alextheman/eslint-plugin": "^4.3.0",
|
|
47
23
|
"@types/node": "^24.10.1",
|
|
48
24
|
"eslint": "^9.39.1",
|
|
49
25
|
"globals": "^16.5.0",
|
|
50
26
|
"husky": "^9.1.7",
|
|
51
27
|
"jsdom": "^27.2.0",
|
|
52
|
-
"prettier": "^3.7.
|
|
53
|
-
"tsdown": "^0.
|
|
28
|
+
"prettier": "^3.7.4",
|
|
29
|
+
"tsdown": "^0.17.0",
|
|
54
30
|
"typescript": "^5.9.3",
|
|
55
31
|
"vite-tsconfig-paths": "^5.1.4",
|
|
56
|
-
"vitest": "^4.0.
|
|
32
|
+
"vitest": "^4.0.15"
|
|
33
|
+
},
|
|
34
|
+
"scripts": {
|
|
35
|
+
"build": "tsdown",
|
|
36
|
+
"change-major": "pnpm version major -m \"Change version number to v%s\"",
|
|
37
|
+
"change-minor": "pnpm version minor -m \"Change version number to v%s\"",
|
|
38
|
+
"change-patch": "pnpm version patch -m \"Change version number to v%s\"",
|
|
39
|
+
"create-local-package": "pnpm run build && rm -f alextheman-utility-*.tgz && pnpm pack",
|
|
40
|
+
"format": "pnpm run format-prettier && pnpm run format-eslint",
|
|
41
|
+
"format-eslint": "eslint --fix --suppress-all \"package.json\" \"src/**/*.ts\" \"tests/**/*.ts\" && rm -f eslint-suppressions.json",
|
|
42
|
+
"format-prettier": "pnpm run format-prettier-typescript && pnpm run format-prettier-javascript",
|
|
43
|
+
"format-prettier-javascript": "prettier --write \"./**/*.js\"",
|
|
44
|
+
"format-prettier-typescript": "prettier --write --parser typescript \"./**/*.ts\"",
|
|
45
|
+
"lint": "pnpm run lint-tsc && pnpm run lint-eslint && pnpm run lint-prettier",
|
|
46
|
+
"lint-eslint": "eslint \"package.json\" \"src/**/*.ts\" \"tests/**/*.ts\"",
|
|
47
|
+
"lint-prettier": "pnpm run lint-prettier-typescript && pnpm run lint-prettier-javascript",
|
|
48
|
+
"lint-prettier-javascript": "prettier --check \"./**/*.js\"",
|
|
49
|
+
"lint-prettier-typescript": "prettier --check --parser typescript \"./**/*.ts\"",
|
|
50
|
+
"lint-tsc": "tsc --noEmit",
|
|
51
|
+
"test": "vitest run",
|
|
52
|
+
"test-watch": "vitest",
|
|
53
|
+
"update-dependencies": "pnpm update --latest && pnpm update",
|
|
54
|
+
"use-live-eslint-plugin": "pnpm uninstall @alextheman/eslint-plugin && pnpm install --save-dev @alextheman/eslint-plugin",
|
|
55
|
+
"use-local-eslint-plugin": "npm --prefix ../eslint-plugin run create-local-package && pnpm uninstall @alextheman/eslint-plugin && pnpm install --save-dev ../eslint-plugin/alextheman-eslint-plugin-*.tgz"
|
|
57
56
|
}
|
|
58
|
-
}
|
|
57
|
+
}
|