mirror of
https://github.com/Xevion/xevion.dev.git
synced 2026-01-31 14:26:37 -06:00
refactor: replace SVG sprite with client-side icon fetching and Rust caching
Eliminates server-side batch rendering and IconSprite pattern in favor of: - Rust handler with moka cache (10k icons, 24h TTL, immutable HTTP headers) - Client Icon component fetches SVGs on-demand with shimmer loading states - Removes renderIconsBatch, tag-icons collection logic, and page load icon preprocessing - Reduces SSR complexity and data serialization overhead
This commit is contained in:
+2
-1
@@ -2,7 +2,7 @@ use std::sync::Arc;
|
||||
|
||||
use crate::{
|
||||
auth::SessionManager, cache::IsrCache, health::HealthChecker, http::HttpClient,
|
||||
tarpit::TarpitState,
|
||||
icon_cache::IconCache, tarpit::TarpitState,
|
||||
};
|
||||
|
||||
/// Application state shared across all handlers
|
||||
@@ -14,6 +14,7 @@ pub struct AppState {
|
||||
pub pool: sqlx::PgPool,
|
||||
pub session_manager: Arc<SessionManager>,
|
||||
pub isr_cache: Arc<IsrCache>,
|
||||
pub icon_cache: Arc<IconCache>,
|
||||
}
|
||||
|
||||
/// Errors that can occur during proxying to Bun
|
||||
|
||||
Reference in New Issue
Block a user