pub struct UnusedLoadDataKey {
pub path: PathBuf,
pub key_name: String,
pub line: u32,
pub col: u32,
pub route_dir: Option<String>,
}Expand description
A SvelteKit +page.{ts,server.ts,js,server.js} load() return-object key
read by no consumer: not off the sibling +page.svelte’s data.<key>, nor
project-wide via page.data.<key> / $page.data.<key>. A dead load key runs
a real server/DB fetch cost on every request for data nothing renders. The
fix is a human call (delete the key, or wire a consumer): a load fetch may
have side effects, so there is no safe auto-fix.
Fields§
§path: PathBufThe producer +page.{ts,server.ts,js,server.js} file declaring the key.
key_name: StringThe returned-object key name read by no consumer.
line: u321-based line number of the key in the return object.
col: u320-based byte column offset of the key.
route_dir: Option<String>The route directory relative to the project root (src/routes/blog), for
agent remediation and per-route trend aggregation. None when not
determinable.