Install & Compatibility
Where this runs
tested against v? · npm install
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
muslnode 18–226 runs
build_error
glibcnode 18–226 runs
build_error
Code
Verified usage
Verified import paths — ran on the pinned version, not inferred.
pinoLogger
✓ import { pinoLogger } from 'hono-pino-logger'
✗ const pinoLogger = require('hono-pino-logger')
ESM only; CommonJS require will fail.
default
✓ import pinoLogger from 'hono-pino-logger'
✗ import { pinoLogger } from 'hono-pino-logger'
Named export pinoLogger is correct; default export does not exist.
typeof pinoLogger
✓ import type { pinoLogger } from 'hono-pino-logger'
✗ import { pinoLogger } from 'hono-pino-logger'
Use type import only for type checking; pinoLogger is a function.
Creates a Hono app with Pino logging for all routes using default logger.
import { Hono } from 'hono'
import { pinoLogger } from 'hono-pino-logger'
const app = new Hono()
app.use('*', pinoLogger())
app.get('/', (c) => c.text('Hello'))
export default app
Errors
Common errors & fixes
Error: Cannot find module 'hono-pino-logger'
Package not installed or typo in package name
fixRun 'npm install hono-pino-logger' and check spelling
TypeError: pinoLogger is not a function
Using default import instead of named import
fixUse '{ pinoLogger }' in import statement Error: hono must be version >=4
Installed hono version is lower than 4
fixUpdate hono: npm install hono@latest
Audit
Dependencies
honorequiredPeer dependency required as middleware runtime
pinooptionalOptional if using default logger; required for custom pino instance