Fetcher react hooks
Skill Ahoo-Wang/skills/plugins/ahoo-fetcher-skills/skills/fetcher-react-hooks
A central aggregation repository for Agent Skills from Ahoo-Wang's open source projects.
npx -y skills add Ahoo-Wang/skills --skill fetcher-react-hooksAssembled from the repository path, not quoted from the project. Check it against their README if it does not work.
One thing to look at
- 3 stars3 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.
What its author says it does
Copied from the file, not written here
Use when building React data-fetching and state hooks with fetcher-react, including usePromiseState, useExecutePromise, useFetcher, useQuery, useFetcherQuery, storage hooks, event subscriptions, utility hooks, Wow query hooks, data monitor hooks, and AbortController behavior.
SKILL.md
2.2 KB, as published. Nobody here has run it
fetcher-react-hooks
Use This Skill When
- The task involves React hooks for Fetcher requests, generic queries, or promise state.
- The task mentions
useFetcher,useQuery,usePromise,useExecutePromise, orPromiseStatus. - The task needs AbortController, unmount safety, race prevention, or auto-execute behavior.
- The task needs storage hooks, event subscriptions, Wow query hooks, or data monitor hooks.
Workflow
- Choose the lowest hook layer that matches the task: promise state, generic execution, Fetcher HTTP, or query helpers.
- Pass
PromiseSupplierfunctions toexecute; do not pass raw promises. - Use
setQueryto update query state andexecute()to rerun current Fetcher queries. - Keep abort, unmount safety, and stale-result behavior explicit in examples and tests.
- Load
references/api.mdfor hook signatures, state machine details, Wow hooks, storage hooks, event hooks, and generated hook helpers.
Key Practices
- Separate query state from rendering state in reusable components.
- Use Fetcher-based query variants when the backend endpoint accepts POST query objects.
- Route UI table/filter work to
fetcher-viewer-componentswhen the task is about data presentation rather than fetching state.
References
references/api.md: Detailed package API, examples, and edge-case guidance. Load it only when the task needs hook architecture, PromiseStatus transitions, hook signatures, Wow query hooks, utility hooks, storage hooks, event hooks, data monitor hooks, and API hook generation.
Related Skills
- $fetcher-integration: Use for core Fetcher request configuration.
- $fetcher-storage: Use for the underlying storage abstraction.
- $fetcher-eventbus: Use for event bus behavior behind event subscriptions and data monitors.
- $fetcher-decorator-service: Use for decorator APIs behind generated hook helpers.
- $fetcher-viewer-components: Use for Ant Design table and filter UI.