Expand description
The shell Ledgeline’s apps share: everything between “a router of API routes plus a built SPA” and “a hardened local server in a desktop window”.
security— the per-process bearer token, theHostguard, the exact-origin CORS allowlist and the security headers (CSP included), plussecurity::harden/security::protect, which put them on a router.spa— serving an app’sRustEmbed-ed SPA same-origin, with the embedded-mode marker injected and a per-response CSP.app_dirs— where an app keeps its own state (AppDirs).recents— the recently-opened store, shared by every app.- [
gui] (theguifeature) — the desktop boot pieces: the in-process server on an ephemeral port, the window, the standard menus, the wry webview with its navigation policy, and the platform glue.
The UI-preferences data model lives one layer down, in
ledgeline_core::ui_prefs, because it is data, not runtime.
Nothing here knows which app it is serving: an app describes itself once
with an AppIdentity and hands it to the pieces that need a name.
Re-exports§
pub use app_dirs::AppDirs;
Modules§
- app_
dirs - Where the APP keeps its own state — the
AppDirsseam (plan 26, A2). - recents
- Recently-opened journals: a tiny persistent list so the CLI can default to the last journal you used and the desktop GUI can offer a File → “Open Recent” submenu.
- security
- Access control and response hardening for the local HTTP server: a
per-process bearer token, a
Host-header guard, an exact-origin CORS allowlist, and the security headers (CSP included) every response carries. - spa
- Serve an app’s built SvelteKit SPA same-origin, in-process.
Structs§
- AppIdentity
- Who the shell is serving: the names an app shows, logs under and hands to its SPA.