1.32.1 • Published 6 months ago
@likec4/log v1.32.1
@likec4/log
Shared interface for logging.
Usage
import { createLogger, loggable, rootLogger } from '@likec4/log'
const logger = createLogger('module')
// OR
const logger = rootLogger.getChild('module')Prefer template strings
const name = 'world'
logger.info`Hello, ${name}!`Logging errors
When logging errors, you can use loggable:
import { loggable } from '@likec4/log'
try {
throw new Error('Something went wrong')
} catch (error) {
logger.error(loggable(error))
// OR pass as second argument
logger.error('An error occurred', { error })
}1.18.0
12 months ago
1.16.0
1 year ago
1.21.0
10 months ago
1.21.1
10 months ago
1.25.0
9 months ago
1.25.1
9 months ago
1.23.0
9 months ago
1.23.1
9 months ago
1.29.0
8 months ago
1.29.1
7 months ago
1.32.0
6 months ago
1.32.1
6 months ago
1.30.0
7 months ago
1.19.0
11 months ago
1.17.1
1 year ago
1.17.0
1 year ago
1.19.2
11 months ago
1.19.1
11 months ago
1.20.1
10 months ago
1.22.0
10 months ago
1.20.2
10 months ago
1.20.0
10 months ago
1.24.1
9 months ago
1.26.0
9 months ago
1.22.1
10 months ago
1.20.3
10 months ago
1.24.0
9 months ago
1.26.1
9 months ago
1.26.2
9 months ago
1.31.0
6 months ago
1.15.0
1 year ago
1.15.1
1 year ago
1.14.0
1 year ago
1.13.0
1 year ago
1.12.2
1 year ago
1.12.1
1 year ago
1.12.0
1 year ago
1.11.0
1 year ago
1.10.1
1 year ago
1.10.0
1 year ago
1.9.0
1 year ago
1.8.1
1 year ago
1.8.0
1 year ago
1.7.4
1 year ago
1.7.3
1 year ago
1.7.2
1 year ago
1.7.1
1 year ago
1.7.0
1 year ago