Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Index your code
hub
/
github.com/nearform/graphql-hooks
/ functions
Functions
194 in github.com/nearform/graphql-hooks
⨍
Functions
194
◇
Types & classes
44
↓ 65 callers
Function
useQuery
( query: string | TypedDocumentNode<ResponseData, Variables>, opts: UseQueryOptions<ResponseData, Variable
packages/graphql-hooks/src/useQuery.ts:20
↓ 44 callers
Function
useClientRequest
( query: string | TypedDocumentNode<ResponseData, Variables>, initialOpts: UseClientRequestOptions<Respons
packages/graphql-hooks/src/useClientRequest.ts:88
↓ 36 callers
Method
request
()
packages/graphql-hooks/test-jsdom/unit/useSubscription.test.tsx:47
↓ 16 callers
Function
fnv1a
(input)
packages/graphql-hooks-memcache/src/fnv1a.js:40
↓ 13 callers
Method
get
(keyObject: CacheKeyObject)
packages/graphql-hooks/src/types/common-types.ts:116
↓ 13 callers
Function
useSubscription
( options: UseSubscriptionOperation<Variables> & { skip?: boolean }, callback: (response: { data?: Res
packages/graphql-hooks/src/useSubscription.ts:8
↓ 12 callers
Function
memCache
({ size = 100, ttl = 0, debug = false, initialState } = {})
packages/graphql-hooks-memcache/src/index.js:8
↓ 12 callers
Method
set
(keyObject: object, data: object)
packages/graphql-hooks-memcache/index.d.ts:11
↓ 11 callers
Method
get
(keyObject: object)
packages/graphql-hooks-memcache/index.d.ts:10
↓ 11 callers
Method
getCacheKey
( operation: Operation, options: UseClientRequestOptions<any, Variables> = {} )
packages/graphql-hooks/src/GraphQLClient.ts:177
↓ 10 callers
Method
keys
()
packages/graphql-hooks-memcache/index.d.ts:14
↓ 9 callers
Method
generateResult
({ fetchError, httpError, graphQLErrors, data, headers }: GenerateResultOptions<Response
packages/graphql-hooks/src/GraphQLClient.ts:157
↓ 9 callers
Function
useMutation
( query: string | TypedDocumentNode<ResponseData, Variables>, options: Omit< UseClientRequestOptions<R
packages/graphql-hooks/src/useMutation.ts:11
↓ 8 callers
Method
getFetchOptions
(operation, fetchOptionsOverrides = {})
packages/graphql-hooks/src/GraphQLClient.ts:211
↓ 6 callers
Function
getInitialState
(opts)
packages/graphql-hooks-ssr/index.js:3
↓ 6 callers
Function
mockQuery
(id: number)
packages/graphql-hooks/test-jsdom/integration/useQuery.test.tsx:218
↓ 6 callers
Method
set
(keyObject: CacheKeyObject, data: object)
packages/graphql-hooks/src/types/common-types.ts:117
↓ 6 callers
Function
useManualQuery
( query: string | TypedDocumentNode<ResponseData, Variables>, options: Omit< UseClientRequestOptions<R
packages/graphql-hooks/src/useManualQuery.ts:11
↓ 5 callers
Function
createRefetchMutationsMap
( refetchAfterMutations?: RefetchAfterMutationsData<TResult, TVariables> )
packages/graphql-hooks/src/createRefetchMutationsMap.ts:19
↓ 5 callers
Function
extractOperationName
(document: DocumentNode | string)
packages/graphql-hooks/src/utils.ts:15
↓ 5 callers
Method
invalidateQuery
(query: Operation | string)
packages/graphql-hooks/src/GraphQLClient.ts:428
↓ 5 callers
Method
logErrorResult
({ result, operation })
packages/graphql-hooks/src/GraphQLClient.ts:124
↓ 5 callers
Method
setQueryData
( query: Operation | string, updater: (oldState?: any) => any )
packages/graphql-hooks/src/GraphQLClient.ts:444
↓ 5 callers
Method
subscribe
(next, onError, onComplete)
packages/graphql-hooks/test-jsdom/unit/useSubscription.test.tsx:51
↓ 4 callers
Function
pipeP
(fns: (() => any)[])
packages/graphql-hooks/src/utils.ts:12
↓ 4 callers
Method
render
(element: ReactElement)
packages/graphql-hooks-ssr/index.d.ts:8
↓ 4 callers
Function
sha256
(query)
packages/graphql-hooks/src/middlewares/apqMiddleware.ts:9
↓ 4 callers
Function
useDeepCompareCallback
( callback: T, deps: DependencyList )
packages/graphql-hooks/src/useDeepCompareCallback.ts:8
↓ 3 callers
Function
callback
packages/graphql-hooks/test-jsdom/unit/useSubscription.test.tsx:158
↓ 3 callers
Function
collectErrors
(entry: object)
packages/graphql-hooks/src/LocalGraphQLClient.ts:140
↓ 3 callers
Function
createMockClient
()
packages/graphql-hooks/test-jsdom/unit/useSubscription.test.tsx:356
↓ 3 callers
Function
createMockResponse
(options: Partial<Response> = {})
packages/graphql-hooks/test-jsdom/utils.ts:4
↓ 3 callers
Function
generateKey
(keyObj)
packages/graphql-hooks-memcache/src/index.js:4
↓ 3 callers
Function
getWrapper
(client: GraphQLClient)
packages/graphql-hooks/test-jsdom/integration/useManualQuery.test.tsx:7
↓ 3 callers
Function
graphql
(source: string)
examples/typescript/src/gql/gql.ts:48
↓ 3 callers
Function
renderHookWithDeps
(callback: (props: T) => U, props: T)
packages/graphql-hooks/test-jsdom/unit/useDeepCompareCallback.test.ts:4
↓ 3 callers
Method
request
( operation: Operation<TVariables>, options?: RequestOptions )
packages/graphql-hooks/src/GraphQLClient.ts:267
↓ 3 callers
Method
run
* Run middleware * @param {opts.client} GraphQLClient instance * @param {opts.operation} Operation object with properties such as query and vari
packages/graphql-hooks/src/Middleware.js:45
↓ 3 callers
Method
saveCache
(cacheKey, value)
packages/graphql-hooks/src/GraphQLClient.ts:199
↓ 3 callers
Method
unsubscribe
()
packages/graphql-hooks/test-jsdom/unit/useSubscription.test.tsx:66
↓ 2 callers
Function
AsyncMidd
(logger, timeout)
packages/graphql-hooks/test-jsdom/integration/GraphQLClient.test.ts:49
↓ 2 callers
Function
CacheMiddleware
()
packages/graphql-hooks/src/middlewares/examples/cacheMiddleware.ts:8
↓ 2 callers
Function
DebugMiddleware
(logger = console.log)
packages/graphql-hooks/src/middlewares/examples/debugMiddleware.ts:8
↓ 2 callers
Function
applyResponseReducer
( responseReducer: RequestOptions['responseReducer'], data, response: Response )
packages/graphql-hooks/src/GraphQLClient.ts:469
↓ 2 callers
Method
clear
()
packages/graphql-hooks-memcache/index.d.ts:13
↓ 2 callers
Function
createMockCache
()
packages/graphql-hooks/test-jsdom/utils.ts:12
↓ 2 callers
Method
createSubscription
(operationPayload)
packages/graphql-hooks/src/GraphQLClient.ts:407
↓ 2 callers
Method
delete
(keyObject: object)
packages/graphql-hooks-memcache/index.d.ts:12
↓ 2 callers
Function
doFetch
()
packages/graphql-hooks/test-jsdom/unit/useClientRequest.test.tsx:375
↓ 2 callers
Function
generateRollupConfig
({ name, overrides, entryPoint })
config/rollup.config.js:16
↓ 2 callers
Method
getInitialState
()
packages/graphql-hooks-memcache/index.d.ts:15
↓ 2 callers
Method
getInitialState
()
packages/graphql-hooks/src/types/common-types.ts:121
↓ 2 callers
Function
getManifest
()
examples/fastify-ssr/src/server/helpers/manifest.js:12
↓ 2 callers
Function
getWrapper
(client: GraphQLClient)
packages/graphql-hooks/test-jsdom/integration/useQuery.test.tsx:13
↓ 2 callers
Function
handleEvents
(payload, actionType)
packages/graphql-hooks/src/useClientRequest.ts:294
↓ 2 callers
Function
stringifyDocumentNode
( document: TNode )
packages/graphql-hooks/src/utils.ts:30
↓ 2 callers
Method
updateData
(previousData: ResponseData, data: ResponseData)
packages/graphql-hooks/src/types/common-types.ts:183
↓ 2 callers
Function
useQueryClient
()
packages/graphql-hooks/src/useQueryClient.ts:5
↓ 1 callers
Function
SyncMidd
packages/graphql-hooks/test-jsdom/integration/GraphQLClient.test.ts:60
↓ 1 callers
Method
addResponseHook
packages/graphql-hooks/src/GraphQLClient.ts:272
↓ 1 callers
Function
appendJSON
(json)
packages/babel-plugin-extract-gql/src/index.js:9
↓ 1 callers
Function
collectErrorsFromArray
(arrayIn: object[])
packages/graphql-hooks/src/LocalGraphQLClient.ts:122
↓ 1 callers
Function
collectErrorsFromObject
(objectIn: object)
packages/graphql-hooks/src/LocalGraphQLClient.ts:104
↓ 1 callers
Function
createMockSubscriptionClient
()
packages/graphql-hooks/test-jsdom/utils.ts:23
↓ 1 callers
Method
delete
(keyObject: CacheKeyObject)
packages/graphql-hooks/src/types/common-types.ts:118
↓ 1 callers
Function
doUnmount
()
packages/graphql-hooks/test-jsdom/unit/useClientRequest.test.tsx:563
↓ 1 callers
Function
filter
()
packages/graphql-hooks/test-jsdom/unit/createRefetchMutationsMap.test.ts:21
↓ 1 callers
Function
fn
()
packages/graphql-hooks/test-jsdom/unit/useClientRequest.test.tsx:770
↓ 1 callers
Function
fnv1aString
(string)
packages/graphql-hooks-memcache/src/fnv1a.js:26
↓ 1 callers
Function
getBundlePath
(manifestKey)
examples/fastify-ssr/src/server/helpers/manifest.js:30
↓ 1 callers
Method
getCache
(cacheKey)
packages/graphql-hooks/src/GraphQLClient.ts:191
↓ 1 callers
Function
getDocument
(query: string)
packages/graphql-hooks/test-jsdom/unit/useClientRequest.test.tsx:21
↓ 1 callers
Function
getTestWrapper
packages/graphql-hooks/test-jsdom/unit/LocalGraphQLClient.test.tsx:83
↓ 1 callers
Function
isGraphQLWsClient
(value: any)
packages/graphql-hooks/src/GraphQLClient.ts:465
↓ 1 callers
Function
isObject
(o: unknown)
packages/graphql-hooks/src/LocalGraphQLClient.ts:100
↓ 1 callers
Function
isPersistedQueryNotFound
(error: APIError<GraphQLResponseError>)
packages/graphql-hooks/src/middlewares/apqMiddleware.ts:25
↓ 1 callers
Function
isRefetchAfterMutationItem
( item: unknown )
packages/graphql-hooks/src/createRefetchMutationsMap.ts:9
↓ 1 callers
Function
isTypedDocumentNode
(item: unknown)
packages/graphql-hooks/src/createRefetchMutationsMap.ts:15
↓ 1 callers
Method
keys
()
packages/graphql-hooks/src/types/common-types.ts:120
↓ 1 callers
Method
onSuccess
( result: Result<ResponseData, TGraphQLError>, variables: Variables )
packages/graphql-hooks/src/types/common-types.ts:187
↓ 1 callers
Method
removeCache
(cacheKey)
packages/graphql-hooks/src/GraphQLClient.ts:205
↓ 1 callers
Method
removeHeader
(key)
packages/graphql-hooks/src/GraphQLClient.ts:119
↓ 1 callers
Function
renderHead
()
examples/fastify-ssr/src/server/handlers/app-shell.js:18
↓ 1 callers
Function
renderScripts
({ initialState })
examples/fastify-ssr/src/server/handlers/app-shell.js:26
↓ 1 callers
Method
requestViaHttp
( operation: Operation<TVariables>, options: RequestOptions = {} )
packages/graphql-hooks/src/GraphQLClient.ts:308
↓ 1 callers
Method
requestViaWS
(operationPayload)
packages/graphql-hooks/src/GraphQLClient.ts:386
↓ 1 callers
Method
setHeader
(key, value)
packages/graphql-hooks/src/GraphQLClient.ts:109
↓ 1 callers
Method
setHeaders
(headers)
packages/graphql-hooks/src/GraphQLClient.ts:114
↓ 1 callers
Function
sideEffectMiddie
packages/graphql-hooks/test-jsdom/unit/Middleware.test.ts:9
↓ 1 callers
Function
start
()
examples/persisted-queries/server/mercurius.ts:35
↓ 1 callers
Function
timeoutPromise
(delayInMs)
packages/graphql-hooks/src/LocalGraphQLClient.ts:94
↓ 1 callers
Function
updateData
()
packages/graphql-hooks/test-jsdom/unit/useQuery.test.tsx:123
↓ 1 callers
Method
verifyConfig
Checks that the given config has the correct required options
packages/graphql-hooks/src/GraphQLClient.ts:78
Function
APQMiddleware
( { operation, client, resolve, reject }, next )
packages/graphql-hooks/src/middlewares/apqMiddleware.ts:49
Function
Add
()
examples/persisted-queries/client/src/App.tsx:14
Function
AddPost
()
examples/typescript/src/App.tsx:51
Function
App
()
packages/babel-plugin-extract-gql/examples/proj-a/src/App.js:11
Function
App
()
examples/persisted-queries/client/src/App.tsx:40
Function
App
()
examples/typescript/src/App.tsx:158
Function
App
()
examples/subscription/src/client/App.js:49
next →
1–100 of 194, ranked by callers