Skip to content

Commit 7e81957

Browse files
authored
Merge pull request #13 from dlealv/doc-improvements
documentation improvements
2 parents 8645fb4 + 0976a50 commit 7e81957

21 files changed

Lines changed: 267 additions & 187 deletions

CHANGELOG.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,11 @@ All notable changes to this project will be documented in this file.
55
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
66

77
---
8+
## [2.1.3] – 2025-07-15
9+
### Changed
10+
- Updated `README.md` with minor corrections about extra field output
11+
- Updated the `README.md` including external function documentation
12+
813
## [2.1.2] – 2025-07-12
914
### Fixed
1015
- Removed the call `this.clearCellIfNotEmpty("")` in `ExcelAppender.constructor` since it produces an error in Office Script indicating: `Unexpected token 'this'`.

README.md

Lines changed: 108 additions & 37 deletions
Large diffs are not rendered by default.

dist/logger.ts

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -881,9 +881,10 @@ class LayoutImpl implements Layout {
881881
* Formats a log event as a short string as follows '[type] message'.
882882
* If extraFields are present in the event, they will be appended as a JSON object (surrounded by braces) to the output.
883883
* Example: `[ERROR] Something bad happened {"user":"dlealv","id":42}`.
884-
* Defined as a named function to ensure toString() returns the function name.
884+
* Defined as a named function to ensure `toString()` of `LayoutImpl` returns the function name.
885+
* @param event - The log event to format.
886+
* @returns A formatted string representation of the log event, as it will be sent to the appenders.
885887
*/
886-
887888
LayoutImpl.shortFormatterFun = Object.freeze(function shortLayoutFormatterFun(event: LogEvent): string {
888889
const sType = LOG_EVENT[event.type]
889890
let extraFieldsStr = ""
@@ -898,9 +899,10 @@ LayoutImpl.shortFormatterFun = Object.freeze(function shortLayoutFormatterFun(ev
898899
* The timestamp is formatted as `YYYY-MM-DD HH:mm:ss,SSS`.
899900
* If extraFields are present in the event, they will be appended as a JSON object (surrounded by braces) to the output.
900901
* Example: `[2025-06-19 15:06:41,123] [ERROR] Something bad happened {"user":"dlealv","id":42}`.
901-
* Defined as a named function to ensure toString() returns the function name.
902+
* Defined as a named function to ensure `toString()` of `LayoutImpl` returns the function name.
903+
* @param event - The log event to format.
904+
* @returns A formatted string representation of the log event, as it will be sent to the appenders.
902905
*/
903-
904906
LayoutImpl.defaultFormatterFun = Object.freeze(function defaultLayoutFormatterFun(event: LogEvent): string {
905907
const sDATE = Utility.date2Str(event.timestamp)
906908
const sType = LOG_EVENT[event.type]

docs/typedoc/classes/AbstractAppender.html

Lines changed: 14 additions & 14 deletions
Large diffs are not rendered by default.

docs/typedoc/classes/ConsoleAppender.html

Lines changed: 16 additions & 16 deletions
Large diffs are not rendered by default.

docs/typedoc/classes/ExcelAppender.html

Lines changed: 18 additions & 18 deletions
Large diffs are not rendered by default.

docs/typedoc/classes/LayoutImpl.html

Lines changed: 9 additions & 9 deletions
Large diffs are not rendered by default.

docs/typedoc/classes/LogEventImpl.html

Lines changed: 9 additions & 9 deletions
Large diffs are not rendered by default.

docs/typedoc/classes/LoggerImpl.html

Lines changed: 27 additions & 27 deletions
Large diffs are not rendered by default.

docs/typedoc/classes/ScriptError.html

Lines changed: 5 additions & 5 deletions
Large diffs are not rendered by default.

0 commit comments

Comments
 (0)