1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
//! The Client Exposure Firewall: explicit, deterministic contracts for
//! Inertia page props.
//!
//! Contracts describe only pages and browser props. They are not a route
//! registry -- Axum remains the sole owner of route selection.
//!
//! The firewall's rule is one sentence: **`serde::Serialize` does not mean
//! browser-safe.** Only a type that explicitly implements [`ClientData`] may
//! cross the browser boundary through [`Inertia::render_page`]. An internal
//! domain model that merely derives `Serialize` cannot accidentally reach
//! the browser, because `render_page` requires `P: ClientData`.
//!
//! The same metadata graph drives the cross-stack linker and the generated
//! TypeScript contract -- there is one source of truth, not two.
//!
//! Each responsibility lives in its own file:
//!
//! * [`contract_type`] -- [`ContractType`], the JSON-compatible browser type.
//! * [`prop_schema`] -- [`PropSchema`], one prop's type and requiredness.
//! * [`props_schema`] -- [`PropsSchema`], the browser prop object schema.
//! * [`client_data`] -- [`ClientData`] and [`PageProps`], the exposure traits.
//! * [`page_contract`] -- [`PageContract`], [`PageContractEntry`] and
//! [`PageType`], page identity bound to a prop type.
//! * [`page_schema`] -- [`PageSchema`], one registered page's schema.
//! * [`registry`] -- [`PageContracts`], the explicit registry.
//! * [`artifact`] -- [`ContractArtifact`], the machine-readable output.
//! * [`error`] -- [`ContractError`], registration failures.
//!
//! [`Inertia::render_page`]: crate::inertia::Inertia::render_page
pub use ContractArtifact;
pub use ;
pub use ContractType;
pub use ContractError;
pub use ;
pub use PageSchema;
pub use PropSchema;
pub use PropsSchema;
pub use PageContracts;