docs: document server-only optional dependencies in AGENTS.md
This commit is contained in:
parent
1a56c0cd3f
commit
7d713cabc2
@ -73,6 +73,8 @@ Dioxus 0.7 fullstack project with **two independent gates** — the most common
|
|||||||
|
|
||||||
**Server-only helpers**: `src/auth/password.rs`, `src/auth/session.rs`, `src/api/auth.rs`, `src/api/comments/helpers.rs`, and several model helper methods are gated with `#[cfg(feature = "server")]` because they are only called from server function bodies, which are stripped in WASM builds.
|
**Server-only helpers**: `src/auth/password.rs`, `src/auth/session.rs`, `src/api/auth.rs`, `src/api/comments/helpers.rs`, and several model helper methods are gated with `#[cfg(feature = "server")]` because they are only called from server function bodies, which are stripped in WASM builds.
|
||||||
|
|
||||||
|
**Server-only dependencies**: Crates that are only used behind `#[cfg(feature = "server")]` (e.g., `argon2`, `uuid`, `regex`, `pulldown-cmark`, `rand`, `http`, `sha2`, `hex`, plus the pre-existing optional server stack) are declared as `optional = true` in `Cargo.toml` and enabled only through the `server` feature. They are not compiled into the WASM frontend.
|
||||||
|
|
||||||
## Dual API Architecture
|
## Dual API Architecture
|
||||||
|
|
||||||
The server exposes two distinct API patterns:
|
The server exposes two distinct API patterns:
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user