About this project

Ora is a Node.js package for displaying an animated spinner in terminal applications. It can be installed with npm and imported as an ES module. The default export accepts text or configuration options, including prefix and suffix text, spinner type, color, cursor visibility, indentation, animation interval, output stream, and forced enablement or silence. Ora provides instance methods for changing the displayed text and styling, checking whether it is spinning, manually rendering frames, stopping, clearing, and marking work as successful, failed, warned, or informational. It also includes oraPromise for associating a spinner with a promise or promise-returning function, with configurable success and failure text and symbols. When enabled, Ora writes to a configurable writable stream, normally stderr. It can handle messages written to that stream while the spinner is active. Spinner output is automatically enabled only in suitable interactive environments and disabled in contexts such as CI unless explicitly configured. Silent mode suppresses all output, while disabled mode suppresses spinner and ANSI styling but may still output text. The package is intended for a single spinner at a time. It is not designed to run in Node.js Worker threads because they are not considered interactive terminals. On some Windows terminals, Unicode support may be unavailable or difficult to detect, so the line spinner or an explicitly selected spinner may be needed.