LWC

This article covers the base LWC methods you'll need to create log records.

File Index

The main JavaScript class that provides core logging functionality for Lightning Web Components:

  • Implements singleton pattern for logging instance management

  • Manages log buffering and auto-flush mechanisms

  • Handles transaction context across component lifecycle

  • Provides methods for different logging levels (ERROR, WARNING, DEBUG, INFO)

A builder class that provides a fluent interface for creating structured log entries:

  • Implements builder pattern for constructing log objects

  • Handles setting of various log attributes (level, category, type, area)

  • Manages component context and runtime information

  • Supports error handling and stack trace processing

Provides utility functions for the logging framework:

  • Stack trace analysis and component identification

  • Transaction ID generation (UUID v4)

  • Runtime information capture

  • Component context extraction

  • Error stack processing

Last updated