Template Variables as Implicit Dependency Declarations
Template Variables as Implicit Dependency Declarations
When a component config contains {{city}} in a request path, that string is doing two things simultaneously: it declares a template slot to be filled at runtime, and it declares a reactive dependency on the city state key. The renderer scans for {{varName}} patterns at mount time to build the dependency graph — no explicit wiring step required.
This is a form of implicit reactivity: the developer writes the config naturally (just describe what the request should look like), and the system infers what needs to re-run when state changes. The same syntax that drives interpolation drives subscription.
The risk is invisibility: a developer who misspells {{citi}} will get a broken URL with no type error and no warning — the dependency graph is inferred from strings, not types. This is the fundamental trade-off of template-driven reactivity: less ceremony upfront, harder to debug when things go wrong. The trade-off is acceptable when the system is simple and the developer is also the one building the config.
Source: data-app-factory — #005 ProxyClient, #009 Reactive wiring See also: Reactive State Bus Pattern, Declarative Data Apps