@thi.ng/rstream-log 5.1.17 → 5.1.19

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
@@ -1,6 +1,6 @@
1
1
  # Change Log
2
2
 
3
- - **Last updated**: 2024-04-23T07:02:18Z
3
+ - **Last updated**: 2024-06-21T19:34:38Z
4
4
  - **Generator**: [thi.ng/monopub](https://thi.ng/monopub)
5
5
 
6
6
  All notable changes to this project will be documented in this file.
package/README.md CHANGED
@@ -7,7 +7,7 @@
7
7
  [![Mastodon Follow](https://img.shields.io/mastodon/follow/109331703950160316?domain=https%3A%2F%2Fmastodon.thi.ng&style=social)](https://mastodon.thi.ng/@toxi)
8
8
 
9
9
  > [!NOTE]
10
- > This is one of 192 standalone projects, maintained as part
10
+ > This is one of 193 standalone projects, maintained as part
11
11
  > of the [@thi.ng/umbrella](https://github.com/thi-ng/umbrella/) monorepo
12
12
  > and anti-framework.
13
13
  >
@@ -78,7 +78,7 @@ For Node.js REPL:
78
78
  const rslog = await import("@thi.ng/rstream-log");
79
79
  ```
80
80
 
81
- Package sizes (brotli'd, pre-treeshake): ESM: 768 bytes
81
+ Package sizes (brotli'd, pre-treeshake): ESM: 766 bytes
82
82
 
83
83
  ## Dependencies
84
84
 
package/format.d.ts CHANGED
@@ -16,7 +16,7 @@ export declare const isoDate: (dt: number) => string;
16
16
  * @param bodyFmt
17
17
  * @param wrap
18
18
  */
19
- export declare const formatString: (dateFmt?: DateFormat, bodyFmt?: BodyFormat, wrap?: ((msg: string, entry: LogEntry) => string) | undefined) => Transducer<LogEntry, string>;
19
+ export declare const formatString: (dateFmt?: DateFormat, bodyFmt?: BodyFormat, wrap?: (msg: string, entry: LogEntry) => string) => Transducer<LogEntry, string>;
20
20
  /**
21
21
  * Takes an array of regex patterns and optional `mask` string. Returns
22
22
  * transducer which replaces all found pattern occurrences with `mask`.
@@ -25,12 +25,14 @@ export declare const formatString: (dateFmt?: DateFormat, bodyFmt?: BodyFormat,
25
25
  *
26
26
  *
27
27
  * @example
28
- * ```ts
29
- * import { Logger, formatString, maskSecrets, writeConsole } from "@thi.ng/rstream-log";
28
+ * ```ts tangle:../export/mask-secrets.ts
29
+ * import {
30
+ * Logger, formatString, maskSecrets, writeConsole
31
+ * } from "@thi.ng/rstream-log";
30
32
  *
31
33
  * const logger = new Logger();
32
34
  *
33
- * logger.transform(
35
+ * logger.stream.transform(
34
36
  * formatString(),
35
37
  * maskSecrets([/(?<=[A-Z0-9_]\=)\w+/g])
36
38
  * ).subscribe(
@@ -38,7 +40,7 @@ export declare const formatString: (dateFmt?: DateFormat, bodyFmt?: BodyFormat,
38
40
  * );
39
41
  *
40
42
  * logger.info("logged in USER=toxi, using TOKEN=123456");
41
- * // [INFO] logger-0: logged in USER=****, using TOKEN=****
43
+ * // [INFO] logger-0: 2024-06-21T12:22:58.004Z logged in USER=****, using TOKEN=****
42
44
  * ```
43
45
  *
44
46
  * @param patterns -
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@thi.ng/rstream-log",
3
- "version": "5.1.17",
3
+ "version": "5.1.19",
4
4
  "description": "Structured, multilevel & hierarchical loggers based on @thi.ng/rstream",
5
5
  "type": "module",
6
6
  "module": "./index.js",
@@ -10,7 +10,7 @@
10
10
  "type": "git",
11
11
  "url": "https://github.com/thi-ng/umbrella.git"
12
12
  },
13
- "homepage": "https://github.com/thi-ng/umbrella/tree/develop/packages/rstream-log#readme",
13
+ "homepage": "https://thi.ng/rstream-log",
14
14
  "funding": [
15
15
  {
16
16
  "type": "github",
@@ -36,18 +36,18 @@
36
36
  "tool:tangle": "../../node_modules/.bin/tangle src/**/*.ts"
37
37
  },
38
38
  "dependencies": {
39
- "@thi.ng/api": "^8.11.1",
40
- "@thi.ng/checks": "^3.6.3",
41
- "@thi.ng/logger": "^3.0.11",
42
- "@thi.ng/rstream": "^8.4.3",
43
- "@thi.ng/strings": "^3.7.32",
44
- "@thi.ng/transducers": "^9.0.4"
39
+ "@thi.ng/api": "^8.11.3",
40
+ "@thi.ng/checks": "^3.6.5",
41
+ "@thi.ng/logger": "^3.0.13",
42
+ "@thi.ng/rstream": "^8.5.1",
43
+ "@thi.ng/strings": "^3.7.34",
44
+ "@thi.ng/transducers": "^9.0.6"
45
45
  },
46
46
  "devDependencies": {
47
- "@microsoft/api-extractor": "^7.43.0",
48
- "esbuild": "^0.20.2",
49
- "typedoc": "^0.25.12",
50
- "typescript": "^5.4.3"
47
+ "@microsoft/api-extractor": "^7.47.0",
48
+ "esbuild": "^0.21.5",
49
+ "typedoc": "^0.25.13",
50
+ "typescript": "^5.5.2"
51
51
  },
52
52
  "keywords": [
53
53
  "datastructure",
@@ -98,5 +98,5 @@
98
98
  ],
99
99
  "year": 2017
100
100
  },
101
- "gitHead": "aed3421c21044c005fbcb7cc37965ccf85a870d2\n"
101
+ "gitHead": "154c95cf9d6bab32174498ec3b5b5d87e42be7f9\n"
102
102
  }