Skip to content

Commit 15b162a

Browse files
Update TypeScript declarations (#307)
* allow default values, rather than explicitly requiring one or the other * update typo in README * update winston-transport to add handleRejections to type Co-authored-by: Kyle Kovacs <[email protected]>
1 parent f165ded commit 15b162a

File tree

4 files changed

+13
-13
lines changed

4 files changed

+13
-13
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ The DailyRotateFile transport can rotate files by minute, hour, day, month, year
2222
* **frequency:** A string representing the frequency of rotation. This is useful if you want to have timed rotations, as opposed to rotations that happen at specific moments in time. Valid values are '#m' or '#h' (e.g., '5m' or '3h'). Leaving this null relies on `datePattern` for the rotation times. (default: null)
2323
* **datePattern:** A string representing the [moment.js date format](http://momentjs.com/docs/#/displaying/format/) to be used for rotating. The meta characters used in this string will dictate the frequency of the file rotation. For example, if your datePattern is simply 'HH' you will end up with 24 log files that are picked up and appended to every day. (default: 'YYYY-MM-DD')
2424
* **zippedArchive:** A boolean to define whether or not to gzip archived log files. (default: 'false')
25-
* **filename:** Filename to be used to log to. This filename can include the `%DATE%` placeholder which will include the formatted datePattern at that point in the filename. (default: 'winston.log.%DATE%)
25+
* **filename:** Filename to be used to log to. This filename can include the `%DATE%` placeholder which will include the formatted datePattern at that point in the filename. (default: 'winston.log.%DATE%')
2626
* **dirname:** The directory name to save log files to. (default: '.')
2727
* **stream:** Write directly to a custom stream and bypass the rotation capabilities. (default: null)
2828
* **maxSize:** Maximum size of the file after which it will rotate. This can be a number of bytes, or units of kb, mb, and gb. If using the units, add 'k', 'm', or 'g' as the suffix. The units need to directly follow the number. (default: null)

index.d.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ type RequireOnlyOne<T, Keys extends keyof T = keyof T> =
55
Pick<T, Exclude<keyof T, Keys>>
66
& {
77
[K in Keys]-?:
8-
Required<Pick<T, K>>
8+
Pick<T, K>
99
& Partial<Record<Exclude<Keys, K>, undefined>>
1010
}[Keys];
1111

package-lock.json

Lines changed: 10 additions & 10 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,6 @@
4343
"file-stream-rotator": "^0.5.7",
4444
"object-hash": "^2.0.1",
4545
"triple-beam": "^1.3.0",
46-
"winston-transport": "^4.2.0"
46+
"winston-transport": "^4.4.0"
4747
}
4848
}

0 commit comments

Comments
 (0)