node-ansi-logger 3.2.0-dev-20260206-dc61678 → 3.2.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/CHANGELOG.md CHANGED
@@ -18,7 +18,7 @@ If you like this project and find it useful, please consider giving it a star on
18
18
 
19
19
  <a href="https://www.buymeacoffee.com/luligugithub"><img src="https://matterbridge.io/assets/bmc-button.svg" alt="Buy me a coffee" width="120"></a>
20
20
 
21
- ## [3.2.0] - 2026-02-03
21
+ ## [3.2.0] - 2026-02-06
22
22
 
23
23
  ### Added
24
24
 
package/README.md CHANGED
@@ -26,7 +26,7 @@ If you like this project and find it useful, please consider giving it a star on
26
26
  - Supports environment variable NO_COLOR=1 (https://no-color.org/).
27
27
  - It is also possible to pass a top level logger (like Homebridge or Matter logger) and AnsiLogger will use it
28
28
  for output instead of console.
29
- - Includes also a fully customizable stringify funtions with colors (it is bigint aware and manage circular reference).
29
+ - Includes also a fully customizable stringify funtion with colors (it is bigint aware and manage circular reference).
30
30
 
31
31
  ## Getting Started
32
32
 
@@ -24,49 +24,49 @@
24
24
  /**
25
25
  * Stringify the payload as a JSON string with no colors.
26
26
  *
27
- * @param {object} payload - The object to stringify.
27
+ * @param {unknown} payload - The object to stringify.
28
28
  * @returns {string} A JSON string representation of the payload.
29
29
  */
30
30
  export declare function payloadStringify(payload: unknown): string;
31
31
  /**
32
32
  * Stringify the payload as a JSON string with no colors.
33
33
  *
34
- * @param {object} payload - The object to stringify.
34
+ * @param {unknown} payload - The object to stringify.
35
35
  * @returns {string} A JSON string representation of the payload.
36
36
  */
37
37
  export declare function jsonStringify(payload: unknown): string;
38
38
  /**
39
39
  * Stringify the payload as a JSON string with colors.
40
40
  *
41
- * @param {object} payload - The object to stringify.
41
+ * @param {unknown} payload - The object to stringify.
42
42
  * @returns {string} A colored JSON string representation of the payload.
43
43
  */
44
44
  export declare function colorStringify(payload: unknown): string;
45
45
  /**
46
46
  * Stringify the payload for history logging with specific colors.
47
47
  *
48
- * @param {object} payload - The object to stringify.
48
+ * @param {unknown} payload - The object to stringify.
49
49
  * @returns {string} A colored JSON string representation of the payload for history.
50
50
  */
51
51
  export declare function historyStringify(payload: unknown): string;
52
52
  /**
53
53
  * Stringify the payload for MQTT with specific colors.
54
54
  *
55
- * @param {object} payload - The object to stringify.
55
+ * @param {unknown} payload - The object to stringify.
56
56
  * @returns {string} A colored JSON string representation of the payload for MQTT.
57
57
  */
58
58
  export declare function mqttStringify(payload: unknown): string;
59
59
  /**
60
60
  * Stringify the payload for debugging with specific colors.
61
61
  *
62
- * @param {object} payload - The object to stringify.
62
+ * @param {unknown} payload - The object to stringify.
63
63
  * @returns {string} A colored JSON string representation of the payload for debugging.
64
64
  */
65
65
  export declare function debugStringify(payload: unknown): string;
66
66
  /**
67
67
  * Stringify the payload with customizable colors and quotes.
68
68
  *
69
- * @param {object} payload - The object to stringify.
69
+ * @param {unknown} payload - The object to stringify.
70
70
  * @param {boolean} enableColors - Whether to enable colors in the output.
71
71
  * @param {number} colorPayload - Color for the payload (default: 252).
72
72
  * @param {number} colorKey - Color for the keys (default: 250).
package/dist/stringify.js CHANGED
@@ -24,7 +24,7 @@
24
24
  /**
25
25
  * Stringify the payload as a JSON string with no colors.
26
26
  *
27
- * @param {object} payload - The object to stringify.
27
+ * @param {unknown} payload - The object to stringify.
28
28
  * @returns {string} A JSON string representation of the payload.
29
29
  */
30
30
  export function payloadStringify(payload) {
@@ -33,7 +33,7 @@ export function payloadStringify(payload) {
33
33
  /**
34
34
  * Stringify the payload as a JSON string with no colors.
35
35
  *
36
- * @param {object} payload - The object to stringify.
36
+ * @param {unknown} payload - The object to stringify.
37
37
  * @returns {string} A JSON string representation of the payload.
38
38
  */
39
39
  export function jsonStringify(payload) {
@@ -42,7 +42,7 @@ export function jsonStringify(payload) {
42
42
  /**
43
43
  * Stringify the payload as a JSON string with colors.
44
44
  *
45
- * @param {object} payload - The object to stringify.
45
+ * @param {unknown} payload - The object to stringify.
46
46
  * @returns {string} A colored JSON string representation of the payload.
47
47
  */
48
48
  export function colorStringify(payload) {
@@ -51,7 +51,7 @@ export function colorStringify(payload) {
51
51
  /**
52
52
  * Stringify the payload for history logging with specific colors.
53
53
  *
54
- * @param {object} payload - The object to stringify.
54
+ * @param {unknown} payload - The object to stringify.
55
55
  * @returns {string} A colored JSON string representation of the payload for history.
56
56
  */
57
57
  export function historyStringify(payload) {
@@ -60,7 +60,7 @@ export function historyStringify(payload) {
60
60
  /**
61
61
  * Stringify the payload for MQTT with specific colors.
62
62
  *
63
- * @param {object} payload - The object to stringify.
63
+ * @param {unknown} payload - The object to stringify.
64
64
  * @returns {string} A colored JSON string representation of the payload for MQTT.
65
65
  */
66
66
  export function mqttStringify(payload) {
@@ -69,7 +69,7 @@ export function mqttStringify(payload) {
69
69
  /**
70
70
  * Stringify the payload for debugging with specific colors.
71
71
  *
72
- * @param {object} payload - The object to stringify.
72
+ * @param {unknown} payload - The object to stringify.
73
73
  * @returns {string} A colored JSON string representation of the payload for debugging.
74
74
  */
75
75
  export function debugStringify(payload) {
@@ -78,7 +78,7 @@ export function debugStringify(payload) {
78
78
  /**
79
79
  * Stringify the payload with customizable colors and quotes.
80
80
  *
81
- * @param {object} payload - The object to stringify.
81
+ * @param {unknown} payload - The object to stringify.
82
82
  * @param {boolean} enableColors - Whether to enable colors in the output.
83
83
  * @param {number} colorPayload - Color for the payload (default: 252).
84
84
  * @param {number} colorKey - Color for the keys (default: 250).
@@ -1,12 +1,12 @@
1
1
  {
2
2
  "name": "node-ansi-logger",
3
- "version": "3.2.0-dev-20260206-dc61678",
3
+ "version": "3.2.0",
4
4
  "lockfileVersion": 3,
5
5
  "requires": true,
6
6
  "packages": {
7
7
  "": {
8
8
  "name": "node-ansi-logger",
9
- "version": "3.2.0-dev-20260206-dc61678",
9
+ "version": "3.2.0",
10
10
  "license": "Apache-2.0",
11
11
  "engines": {
12
12
  "node": ">=20.0.0 <21.0.0 || >=22.0.0 <23.0.0 || >=24.0.0 <25.0.0"
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "node-ansi-logger",
3
- "version": "3.2.0-dev-20260206-dc61678",
3
+ "version": "3.2.0",
4
4
  "description": "Enhanced Ansi Color Logging and Stringify for Node.js in type script",
5
5
  "author": "https://github.com/Luligu",
6
6
  "license": "Apache-2.0",