@web-ts-toolkit/utils 0.44.0 → 0.45.0
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/README.md +9 -6
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -63,13 +63,16 @@ parseBooleanString('true', false);
|
|
|
63
63
|
|
|
64
64
|
## Main Exports
|
|
65
65
|
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
-
|
|
66
|
+
58 functions plus the `PropertyPath` type, all from the package root
|
|
67
|
+
(see `src/index.ts`):
|
|
68
|
+
|
|
69
|
+
- object/path helpers: `get`, `set`, `hasOwn`, `pick`, `pickBy`, `omit`, `omitBy`, `assign`, `keys`, `mapKeys`, `mapValues`, `toStringRecord`
|
|
70
|
+
- collection helpers: `map`, `filter`, `forEach`, `eachRight`, `join`, `reduce`, `find`, `flatten`, `flattenDeep`, `compact`, `uniq`, `uniqBy`, `difference`, `intersection`, `intersectionBy`, `groupBy`, `orderBy`, `sum`, `sumBy`
|
|
71
|
+
- guards: `isArray`, `isBoolean`, `isEmpty`, `isEqual`, `isFunction`, `isMatch`, `isNaN`, `isNil`, `isNumber`, `isObject`, `isPlainObject`, `isPromise`, `isString`, `isUndefined`
|
|
72
|
+
- string helpers: `startCase`, `upperCase`, `padEnd`
|
|
70
73
|
- URL helpers: `addLeadingSlash`, `removeConsecutiveSlashesFromUrl`, `normalizeUrlPath`
|
|
71
74
|
- async helpers: `mapValuesAsync`, `toAsyncFn`
|
|
72
|
-
- misc: `castArray`, `arrayToRecord`, `
|
|
75
|
+
- misc: `castArray`, `arrayToRecord`, `cloneDeep`, `noop`, `parseBooleanString`
|
|
73
76
|
|
|
74
77
|
## Path Grammar And Mutation Rules
|
|
75
78
|
|
|
@@ -85,7 +88,7 @@ segment arrays (`['a', 'b']`).
|
|
|
85
88
|
segments, and malformed brackets are unspecified (no Lodash parity).
|
|
86
89
|
- Mutation segments `__proto__`, `constructor`, and `prototype` (quoted
|
|
87
90
|
or not) are rejected before any write: `set` returns its target
|
|
88
|
-
unchanged and `omit
|
|
91
|
+
unchanged and `omit` is a no-op.
|
|
89
92
|
- In `pick`/`omit`, a flat string array is a **list** of paths
|
|
90
93
|
(`pick(o, ['a', 'b'])` picks keys `a` and `b`); pass a nested array for
|
|
91
94
|
a single segmented path (`pick(o, [['a', 'b']])` picks `a.b`).
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "@web-ts-toolkit/utils",
|
|
3
3
|
"description": "Shared collection, object, async, and URL helpers used across workspace packages",
|
|
4
4
|
"homepage": "https://web-ts-toolkit.pages.dev/docs/packages/utils",
|
|
5
|
-
"version": "0.
|
|
5
|
+
"version": "0.45.0",
|
|
6
6
|
"sideEffects": false,
|
|
7
7
|
"keywords": [
|
|
8
8
|
"utilities",
|