Releases
v4.0.0
morrys
released this
18 Jan 11:26
Breaking Change
removed support to Mutation HOC
useRefetch no longer exists
remove fetchObserver in useQuery in favor of onComplete property
changed the return type:
useQuery
-> const { data, isLoading, error, retry} = useQuery(query, variables);
(removed cached and added isLoading)
useRefetchable
-> const { data, refetch, isLoading, error } = useRefetchable(node, ref);
(before [data, refetch])
usePagination
-> const { data, hasNext, isLoadingNext, hasPrevious, isLoadingPrevious, isLoading, refetch, loadNext, loadPrevious, errorNext, errorPrevious, error } = usePagination(node, ref);
(before [ data, { isLoading, hasMore, loadMore } ])
usePagination now uses the @refetchable directive
Fixed
typesafe onMutation promise #132
Improved
added useRefetchableFragment hook with suspense
added usePaginationFragment hook with suspense
useSuspenseFragment hook with suspense like useFragment in relay-experimental
update dependency fbjs
support relay-runtime v10.x.x
added more tests
Added babel dev-expression in order to reduce bundle size
Removed warning in StrictMode
added example with pagination
documentation, useRefetchable , usePagination
useMutation typing
You can’t perform that action at this time.