A Node.js library for logging by overwriting previous terminal output, enabling progress bars and animations.
log-update is a Node.js library that enables logging by overwriting previous terminal output, allowing for dynamic updates like progress bars and animations. It solves the problem of cluttered console output in CLI tools by providing smooth, in-place updates. The library supports partial redraws to minimize flicker and offers methods for both temporary and persistent logging.
Node.js developers building command-line interfaces (CLIs) that require dynamic output, such as progress indicators, spinners, or real-time status updates. It's also useful for tool authors creating interactive terminal applications.
Developers choose log-update for its simplicity, efficiency, and reliability in handling terminal output updates. Its partial redraw capability reduces visual noise, and the flexible API supports both stdout and stderr with session management, making it a go-to for polished CLI experiences.
Log by overwriting the previous output in the terminal. Useful for rendering progress bars, animations, etc.
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
Reduces flicker by only updating changed parts of the output, as highlighted in the README, making animations and progress bars smoother.
Provides separate logUpdate and logUpdateStderr methods for stdout and stderr, ensuring consistent logging behavior across output streams.
Includes persist(), clear(), and done() methods to control whether output is temporary or permanent, enhancing CLI session handling without cluttering scrollback.
Allows setting defaultWidth and defaultHeight for non-TTY environments, such as when output is piped, ensuring reliable behavior without terminal size info.
Requires external libraries like chalk or yoctocolors for colorization, adding dependencies and setup complexity for basic visual enhancements.
Focused on in-place line updates; not suitable for complex terminal UIs with multiple dynamic regions or advanced graphical layouts, lacking out-of-the-box components.
Performance and functionality can degrade in non-interactive terminals, as acknowledged in the README with the need for manual dimension configurations.