mirror of
https://github.com/InsanusMokrassar/KSLog.git
synced 2026-01-17 17:37:52 +00:00
generate kdocs
This commit is contained in:
@@ -1,5 +1,23 @@
|
||||
package dev.inmo.kslog.common
|
||||
|
||||
/**
|
||||
* JavaScript platform implementation of the default logger
|
||||
*
|
||||
* Uses browser/Node.js `console` API as the logging backend, mapping KSLog levels
|
||||
* to console methods:
|
||||
* - [LogLevel.TRACE] → console.trace() + console.debug()
|
||||
* - [LogLevel.DEBUG] → console.debug()
|
||||
* - [LogLevel.VERBOSE] → console.info()
|
||||
* - [LogLevel.INFO] → console.info()
|
||||
* - [LogLevel.WARNING] → console.warn()
|
||||
* - [LogLevel.ERROR] → console.error()
|
||||
* - [LogLevel.ASSERT] → console.error()
|
||||
*
|
||||
* Logs can be viewed in the browser's Developer Tools console or Node.js console output.
|
||||
*
|
||||
* **Note**: The tag parameter is ignored in JS implementation as console methods
|
||||
* don't support tagging natively.
|
||||
*/
|
||||
actual var KSLoggerDefaultPlatformLoggerLambda: (level: LogLevel, tag: String, message: Any, throwable: Throwable?) -> Unit = { l, _, m, e ->
|
||||
val args = e ?.let {
|
||||
arrayOf(m, e)
|
||||
|
||||
Reference in New Issue
Block a user