During development or debugging, you may need to enable or disable logging globally in a JavaScript application.To achieve this, store the original console.log function and create a control function that toggles logging on and off.By setting logging_enabled to true or false, you can control whether console.log behaves as usual or becomes an empty function.This method provides global control over logging, allowing you to keep the console clean and prevent unnecessary clutter during debugging.