review-logging-patterns

Convert console logs into wide events and structured errors in Nuxt/Nitro routes.

1.7k|57|Updated Jan 24, 2026
One-click install
npx skills add https://github.com/HugoRCD/evlog --skill review-logging-patterns
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: review-logging-patterns
Source: https://github.com/HugoRCD/evlog/tree/main/skills/evlog
Command: npx skills add https://github.com/HugoRCD/evlog --skill review-logging-patterns

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

Review code for logging patterns and evlog adoption. Identify console.log spam, unstructured errors, and missing contextual data; provide guidance to convert to wide events and structured errors, improving debuggability.

Core Features & Use Cases

  • Guides wide-event design for per-request context accumulation and automatic emission
  • Enforces structured errors via createError and contextual fields (why, fix, link)
  • Provides code-review workflow with auto-import guidelines (useLogger, createRequestLogger)
  • References best practices for log draining and adapters (Axiom, OTLP)

Quick Start

Run a code review to transform scattered console.logs into wide events and structured errors.

Frequently Asked Questions about review-logging-patterns

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I refactor console.log statements into structured logging in Nuxt or Nitro?

Convert console.log statements into wide events by enforcing useLogger(event) for per-request context and createError() for structured errors. This refactoring transitions scattered console spam into debuggable, contextual wide-event logs.

What are wide events in logging and when should I use them?

Wide events are structured log entries that accumulate per-request contextual data and emit it automatically. Use wide events to replace unstructured console logs and improve debuggability by capturing rich, request-scoped context.

How do I create structured errors in a Node.js backend?

Create structured errors in a Node.js backend by using createError() with contextual fields such as why, fix, and link. This ensures errors carry actionable debugging context rather than unformatted stack traces.

Does this logging pattern review work with standalone scripts outside of Nuxt?

Yes, the logging pattern review applies to standalone scripts, Node.js backends, and Nuxt/Nitro routes. It audits and refactors logging, error handling, and request-scoped context across these environments to ensure wide-event adoption.

What is the best way to audit code for missing contextual data in logs?

The best way to audit code for missing contextual data is to run a code review that identifies console.log spam and unstructured errors, then provides guidance to convert them into wide events with per-request context accumulation.