jarq 0.8.2

An interactive jq-like JSON query tool with a TUI
Documentation
use crate::ui::RenderOptions;

/// Output formatting options
pub(super) struct DisplayOptions {
    pub(super) wrap_lines: bool,
    pub(super) raw_output: bool,
    pub(super) compact: bool,
    pub(super) slurp: bool,
}

impl DisplayOptions {
    pub(super) fn new() -> Self {
        Self {
            wrap_lines: false,
            raw_output: false,
            compact: false,
            slurp: false,
        }
    }

    pub(super) fn render_options(&self) -> RenderOptions {
        RenderOptions {
            raw_output: self.raw_output,
            compact: self.compact,
        }
    }
}