nhb-toolbox 4.0.44 → 4.0.46

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.
@@ -40,6 +40,9 @@ const generateQueryParams = (params = {}) => {
40
40
  exports.generateQueryParams = generateQueryParams;
41
41
  /**
42
42
  * * Get query params as standard `JavaScript` Object `Record<string, string>`.
43
+ *
44
+ * - **Note:** *Extracts query parameters from the current URL (window.location.search).*
45
+ *
43
46
  * @returns Query string as key-value paired object. `Record<string, string>`.
44
47
  */
45
48
  function getQueryParams() {
@@ -60,6 +63,8 @@ function updateQueryParam(key, value) {
60
63
  * Supports multiple values for the same key by returning arrays.
61
64
  * Optionally parses primitive string values into actual types (e.g., "1" → 1, "true" → true).
62
65
  *
66
+ * - **Note:** *This function does **not** access or depend on `current URL` a.k.a `window.location.search`.*
67
+ *
63
68
  * @param query - The query string to parse.
64
69
  * @param parsePrimitives - Whether to convert stringified primitives into real values (default: true).
65
70
  * @returns An object where keys are strings and values can be string, array, number, boolean, or null.
@@ -16,6 +16,9 @@ import type { QueryString } from '../string/types';
16
16
  export declare const generateQueryParams: <T extends QueryObject>(params?: T) => QueryString;
17
17
  /**
18
18
  * * Get query params as standard `JavaScript` Object `Record<string, string>`.
19
+ *
20
+ * - **Note:** *Extracts query parameters from the current URL (window.location.search).*
21
+ *
19
22
  * @returns Query string as key-value paired object. `Record<string, string>`.
20
23
  */
21
24
  export declare function getQueryParams(): Record<string, string>;
@@ -30,6 +33,8 @@ export declare function updateQueryParam(key: string, value: string): void;
30
33
  * Supports multiple values for the same key by returning arrays.
31
34
  * Optionally parses primitive string values into actual types (e.g., "1" → 1, "true" → true).
32
35
  *
36
+ * - **Note:** *This function does **not** access or depend on `current URL` a.k.a `window.location.search`.*
37
+ *
33
38
  * @param query - The query string to parse.
34
39
  * @param parsePrimitives - Whether to convert stringified primitives into real values (default: true).
35
40
  * @returns An object where keys are strings and values can be string, array, number, boolean, or null.
@@ -1 +1 @@
1
- {"version":3,"file":"query.d.ts","sourceRoot":"","sources":["../../../src/dom/query.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,WAAW,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;AACjE,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,iBAAiB,CAAC;AAGnD;;;;;;;;;;;;GAYG;AACH,eAAO,MAAM,mBAAmB,GAAI,CAAC,SAAS,WAAW,WAChD,CAAC,KACP,WAkCF,CAAC;AAEF;;;GAGG;AACH,wBAAgB,cAAc,IAAI,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAEvD;AAED;;;;GAIG;AACH,wBAAgB,gBAAgB,CAAC,GAAG,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,QAI1D;AAED;;;;;;;;GAQG;AACH,eAAO,MAAM,gBAAgB,UACrB,MAAM,gCAEX,YAqBF,CAAC"}
1
+ {"version":3,"file":"query.d.ts","sourceRoot":"","sources":["../../../src/dom/query.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,WAAW,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;AACjE,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,iBAAiB,CAAC;AAGnD;;;;;;;;;;;;GAYG;AACH,eAAO,MAAM,mBAAmB,GAAI,CAAC,SAAS,WAAW,WAChD,CAAC,KACP,WAkCF,CAAC;AAEF;;;;;;GAMG;AACH,wBAAgB,cAAc,IAAI,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAEvD;AAED;;;;GAIG;AACH,wBAAgB,gBAAgB,CAAC,GAAG,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,QAI1D;AAED;;;;;;;;;;GAUG;AACH,eAAO,MAAM,gBAAgB,UACrB,MAAM,gCAEX,YAqBF,CAAC"}
@@ -34,6 +34,9 @@ export const generateQueryParams = (params = {}) => {
34
34
  };
35
35
  /**
36
36
  * * Get query params as standard `JavaScript` Object `Record<string, string>`.
37
+ *
38
+ * - **Note:** *Extracts query parameters from the current URL (window.location.search).*
39
+ *
37
40
  * @returns Query string as key-value paired object. `Record<string, string>`.
38
41
  */
39
42
  export function getQueryParams() {
@@ -54,6 +57,8 @@ export function updateQueryParam(key, value) {
54
57
  * Supports multiple values for the same key by returning arrays.
55
58
  * Optionally parses primitive string values into actual types (e.g., "1" → 1, "true" → true).
56
59
  *
60
+ * - **Note:** *This function does **not** access or depend on `current URL` a.k.a `window.location.search`.*
61
+ *
57
62
  * @param query - The query string to parse.
58
63
  * @param parsePrimitives - Whether to convert stringified primitives into real values (default: true).
59
64
  * @returns An object where keys are strings and values can be string, array, number, boolean, or null.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "nhb-toolbox",
3
- "version": "4.0.44",
3
+ "version": "4.0.46",
4
4
  "description": "A versatile collection of smart, efficient, and reusable utility functions for everyday development needs.",
5
5
  "main": "dist/cjs/index.js",
6
6
  "module": "dist/esm/index.js",