Showcase
Each example shows real output produced by origin itself, from files in the project repository. Input on the left, output on the right.
Manifest to capability file
examples/demo/app.tomlDetail: Manifest to capability file →# What this product is (ADR-0021).
#
# The composition root in src-tauri/src/lib.rs answers the other question — how it is
# assembled. Everything derivable from this file is generated, not hand-written:
# `cargo xtask generate`.
[origin]
version = "0.2.0"
[product]
id = "dev.origin.demo"
name = "Origin Demo"
version = "0.1.0"
description = "Reference application for the Origin architecture."
[platform]
tray = true
notifications = true
single_instance = true
window_state = true
[modules]
pulse = true
[security.windows]
main = { profile = "standard-dashboard" }{
"$schema": "../gen/schemas/desktop-schema.json",
"identifier": "standard-dashboard",
"description": "Main window: reads application state and receives platform events. No filesystem, no shell, no process execution. Generated from app.toml — do not edit.",
"windows": [
"main"
],
"permissions": [
"core:default",
"core:event:allow-listen",
"core:event:allow-unlisten"
]
}Rust type to TypeScript binding
examples/demo/src-tauri/src/pulse.rsDetail: Rust type to TypeScript binding →#[derive(Debug, Clone, Serialize, ts_rs::TS)]
pub struct PulseSnapshot {
pub health: Health,
pub metric: Option<Metric>,
pub alerts: Vec<Alert>,
}// Generated from PulseSnapshot in src-tauri/src/pulse.rs. Do not edit.
import type { Alert, Health, Metric } from "@casoon/origin-client";
export type PulseSnapshot = { health: Health, metric: Metric | null, alerts: Array<Alert>, };