twofold 0.5.0

One document, two views. Markdown share service for humans and agents.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
//! Shared application state injected into all handlers via axum State extractor.

use std::sync::Arc;

use crate::{config::ServeConfig, db::Db, rate_limit::RateLimitStore};

/// Shared application state injected into all handlers via axum State extractor.
#[derive(Clone)]
#[allow(dead_code)] // rate_limit accessed via axum Extension layer, not directly on AppState
pub struct AppState {
    pub db: Db,
    pub config: Arc<ServeConfig>,
    pub rate_limit: Arc<RateLimitStore>,
}