A JavaScript/TypeScript library that collects multiple log messages and emits them as a single JSON log line. Version 0.5.4 is the latest stable release; the project is pre-1.0.0 with documentation promised at 1.0.0. It simplifies structured logging by buffering logs and flushing them as a batch, ideal for reducing I/O in high-throughput Node.js applications. Simpler than full-featured frameworks like Winston or Pino, but limited in features and currently lacks comprehensive docs.
npm install log-bundlerVerified import paths — ran on the pinned version, not inferred.
Show how to create a LogBundler, add individual logs, and flush them as a batch JSON log.
Pin to exact version or prepare for breaking changes.
Use standard output streams instead of custom output file option.
Use 'await bundler.flush()' if flush() returns a promise.
Use 'import { LogBundler } from 'log-bundler'' or 'const { LogBundler } = require('log-bundler')'.Always use lowercase level strings.
Use named import: import { LogBundler } from 'log-bundler'Use import syntax or convert your project to ESM. Alternatively, for CommonJS, use dynamic import: const { LogBundler } = await import('log-bundler')Run: npm install log-bundler
Instantiate LogBundler first: const bundler = new LogBundler(); then call bundler.log()
No dependency data recorded yet.