Skip to content

Commit

Permalink
Rename useFragment to useFragment_experimental (#10075)
Browse files Browse the repository at this point in the history
  • Loading branch information
MrDoomBringer committed Sep 7, 2022
1 parent fcd0452 commit d2c858a
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
6 changes: 3 additions & 3 deletions src/__tests__/__snapshots__/exports.ts.snap
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ Array [
"throwServerError",
"toPromise",
"useApolloClient",
"useFragment",
"useFragment_experimental",
"useLazyQuery",
"useMutation",
"useQuery",
Expand Down Expand Up @@ -243,7 +243,7 @@ Array [
"parser",
"resetApolloContext",
"useApolloClient",
"useFragment",
"useFragment_experimental",
"useLazyQuery",
"useMutation",
"useQuery",
Expand Down Expand Up @@ -282,7 +282,7 @@ Array [
exports[`exports of public entry points @apollo/client/react/hooks 1`] = `
Array [
"useApolloClient",
"useFragment",
"useFragment_experimental",
"useLazyQuery",
"useMutation",
"useQuery",
Expand Down
2 changes: 1 addition & 1 deletion src/react/hooks/__tests__/useFragment.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { renderHook } from '@testing-library/react-hooks';
import userEvent from '@testing-library/user-event';
import { act } from "react-dom/test-utils";

import { useFragment } from "../useFragment";
import { useFragment_experimental as useFragment } from "../useFragment";
import { MockedProvider } from "../../../testing";
import { ApolloProvider } from "../../context";
import {
Expand Down
2 changes: 1 addition & 1 deletion src/react/hooks/useFragment.ts
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ export interface UseFragmentResult<TData> {
lastCompleteResult?: UseFragmentResult<TData>;
}

export function useFragment<TData, TVars>(
export function useFragment_experimental<TData, TVars>(
options: UseFragmentOptions<TData, TVars>,
): UseFragmentResult<TData> {
const { cache } = useApolloClient();
Expand Down

0 comments on commit d2c858a

Please sign in to comment.