React Pattern
Injected mock API client
Pass a stable client function as a dependency so an offline fixture can replace actual network I/O.
Formal Syntax & Structure
react syntaxreact
loadPage({page, scenario, signal})Working Example
Example Snippetreact
const response = await loadPage({page, scenario, signal});