disableConsoleInterception
Disable console interception and restore the original console methods.
Syntax​
disableConsoleInterception(): void
Examples​
Basic Usage​
const logger = InteractiveLogger();
logger.enableConsoleInterception();
// ... later ...
logger.disableConsoleInterception();
// Console methods are now restored to their original behavior
Conditional Interception​
const logger = InteractiveLogger();
if (isDevelopment) {
logger.enableConsoleInterception();
} else {
logger.disableConsoleInterception();
}
Notes​
- Restores the original console methods
- Stops capturing console output to logs
- Safe to call even if interception is not enabled
- Does not affect logs that were already captured
See Also​
- enableConsoleInterception - Enable console interception
- isConsoleInterceptionEnabled - Check if interception is enabled