Skip to content
//! `twice-ui` — desktop client for one or more `twice-server` instances.

mod app;
mod backend;
mod client;
mod profiles;
mod views;

use anyhow::{Result, anyhow};

fn main() -> Result<()> {
    let options = eframe::NativeOptions {
        viewport: egui::ViewportBuilder::default()
            .with_inner_size([1100.0, 700.0])
            .with_title("twice"),
        ..eframe::NativeOptions::default()
    };

    eframe::run_native(
        "twice",
        options,
        Box::new(|cc| Ok(Box::new(app::TwiceApp::new(&cc.egui_ctx)))),
    )
    .map_err(|err| anyhow!("starting the twice UI: {err}"))
}