Skip to main content

@std/log@0.215.0

latest
Works with
It is unknown whether this package works with Browsers, Deno, Node.js, Cloudflare Workers, Bun
It is unknown whether this package works with Browsers
It is unknown whether this package works with Deno
It is unknown whether this package works with Node.js
It is unknown whether this package works with Cloudflare Workers
It is unknown whether this package works with Bun
JSR Score58%
Published2 years ago (0.215.0)

Functions

f
getLevelByName(name: LevelName): LogLevel

Returns the numeric log level associated with the passed, stringy log level name.

f
getLevelName(level: LogLevel): LevelName

Returns the stringy log level name provided the numeric log level.

Type Aliases

T
LevelName = Exclude<keyof LogLevels, number>

Union of valid log level names

T
LogLevel = LogLevels[LevelName]

Union of valid log levels

Variables

v
LogLevelNames: LevelName[]

Permitted log level names

v
LogLevels: { NOTSET: number; DEBUG: number; INFO: number; WARN: number; ERROR: number; CRITICAL: number; }

Use this to retrieve the numeric log level by it's associated name. Defaults to INFO.

  • CRITICAL: number
    No documentation available
  • DEBUG: number
    No documentation available
  • ERROR: number
    No documentation available
  • INFO: number
    No documentation available
  • NOTSET: number
    No documentation available
  • WARN: number
    No documentation available

Report package

Please provide a reason for reporting this package. We will review your report and take appropriate action.

Please review the JSR usage policy before submitting a report.

Add Package

deno add jsr:@std/log

Import symbol

import * as mod from "@std/log/levels";
or

Import directly with a jsr specifier

import * as mod from "jsr:@std/log/levels";