data-fetching-architecture
A reference skill in the LobeHub repository, not called directly by users, on how server data moves through LobeHub's web front end.
スキルの内容
A reference skill in the LobeHub repository, not called directly by users, on how server data moves through LobeHub's web front end. Services own API calls, stores expose fetch hooks that keep a replica of server data, and components read through selectors. New server data must use the project's replica library rather than new SWR keys, which a test freezes. It covers keeping read and refresh parameters the same, skipping requests without a required ID, avoiding fetches in effects, optimistic updates with rollback, telling an unloaded result from an empty one, showing first-load errors, keeping content during background failures, and moving old effect-based fetching into store hooks.
できること
- Add server data through replica-backed store hooks
- Write mutations with optimistic updates and rollback
- Render loading, empty and error states correctly
- Migrate effect-based fetching to store hooks
概要
- 公開元
- LobeHub
インストール
プロジェクトのドキュメントに、確認できるインストール手順がありません。 プロジェクトの手順を見る
含まれるファイル
- references/home-first-paint.md
- references/walkthrough.md
MCPサーバーやスキルは、お使いのコンピューターでコードを実行したり、データを操作したりできます。インストールする前にソースを確認してください。
詳細
出典
- スキルファイル(SKILL.md)github.com/lobehub/lobehub2026年11月16日
- GitHubリポジトリgithub.com/lobehub/lobehub · 根拠となる項目:公開元, 活動状況2026年11月11日
- スキルファイル(SKILL.md)github.com/lobehub/lobehub · 根拠となる項目:ライセンス2026年11月10日
- リポジトリ内のフォルダ(data-fetching-architecture)github.com/lobehub/lobehub · 根拠となる項目:スクリプトを含む2026年11月10日