We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8ff2bf9 commit 8003ebbCopy full SHA for 8003ebb
docs/core/getting-started/data-dependency.md
@@ -173,7 +173,7 @@ function LoadMore() {
173
const [nextPage, isPending] = useLoading(
174
() => ctrl.fetch(PostResource.getList.getPage, { page: 2 }),
175
);
176
- if (posts?.length % 3 !== 0) return null;
+ if (!posts || posts.length % 3 !== 0) return null;
177
return (
178
<center>
179
<button onClick={nextPage}>{isPending ? "..." : 'Load more'}</button>
0 commit comments