Registry / web-framework / rozenite-graphql-client-devtool

rozenite-graphql-client-devtool

JSON →
library0.0.7jsnpmunverified

rozenite-graphql-client-devtool is an early-stage debugging plugin designed for React Native applications utilizing GraphQL clients, specifically within the Rozenite developer tools platform. Currently at version 0.0.7, this package provides a comprehensive interface for monitoring GraphQL operations, inspecting the client's cache, and exploring the GraphQL schema in real-time. It supports Apollo Client out-of-the-box, with future plans to include URQL and Relay. The project appears to be in active development, releasing updates as features mature rather than on a fixed cadence. Its key differentiators include its integration with the Rozenite ecosystem, strong focus on React Native debugging, and a flexible adapter pattern to support various GraphQL clients, offering granular control over what data (variables, responses) is tracked.

npm install rozenite-graphql-client-devtool
INSTALL
IMPORT
SIG · ROZENITE-GRAPHQL-C
R
rozenite-graphql-client-devtool
web-frameworkjavascriptv0.0.7
Install
—
Import
—
Disk
—
Pass rate
0/ 6
Env Coverage0 / 6
glibc
18–22
musl
18–22
Install & Compatibility
Where this runs
tested against v? · npm install
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
musl
node 18–226 runs
build_error
glibc
node 18–226 runs
build_error
Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

apolloGraphqlDevtoolLink
✓ import { apolloGraphqlDevtoolLink } from 'rozenite-graphql-client-devtool';
✗ const { apolloGraphqlDevtoolLink } = require('rozenite-graphql-client-devtool');
This package primarily uses ESM. Using CommonJS 'require' might lead to import errors in modern React Native projects.
useGraphqlClientDevtool
✓ import { useGraphqlClientDevtool } from 'rozenite-graphql-client-devtool';
✗ import useGraphqlClientDevtool from 'rozenite-graphql-client-devtool';
This is a named export, not a default export. Attempting to import it as a default export will result in an undefined value.
GraphQLClientAdapter
✓ import type { GraphQLClientAdapter } from 'rozenite-graphql-client-devtool';
✗ import { GraphQLClientAdapter } from 'rozenite-graphql-client-devtool';
This symbol is a TypeScript type/interface, used for type annotation when creating custom client adapters. Using `import type` is recommended for type-only imports to improve clarity and allow bundlers to optimize.

This quickstart demonstrates how to integrate rozenite-graphql-client-devtool with an Apollo Client instance in a React Native application, ensuring proper link order and devtool initialization.

import { ApolloClient, InMemoryCache, ApolloLink, HttpLink, ApolloProvider } from '@apollo/client'; import { apolloGraphqlDevtoolLink, useGraphqlClientDevtool } from 'rozenite-graphql-client-devtool'; import React from 'react'; import { View, Text } from 'react-native'; // 1. Create the DevToolLink Link const devToolLink = apolloGraphqlDevtoolLink(); // 2. Create your HTTP Link const httpLink = new HttpLink({ uri: 'https://api.example.com/graphql', }); // 3. Combine links - Rozenite Link MUST be first const client = new ApolloClient({ link: ApolloLink.from([ devToolLink, // ⚠️ IMPORTANT: Must be first to capture all operations httpLink, ]), cache: new InMemoryCache(), }); function MyGraphQLComponent() { return ( <View> <Text>Your GraphQL-powered content here.</Text> </View> ); } function App() { // 4. Initialize the devtool useGraphqlClientDevtool({ client, clientType: 'apollo', includeVariables: true, includeResponseData: true, }); return ( <ApolloProvider client={client}> <MyGraphQLComponent /> </ApolloProvider> ); }
Debug
Known issues
gotchaWhen combining Apollo Links, the `apolloGraphqlDevtoolLink` must be placed first in the `ApolloLink.from` array to ensure it captures all GraphQL operations, including mutations and subscriptions.
fix
Ensure `devToolLink` is the very first element in `ApolloLink.from([devToolLink, ...otherLinks])`.
affects: >=0.0.1
gotchaThis package is currently in early development (version 0.0.7). While functional, the API may undergo changes in future minor or patch releases until a stable 1.0.0 version is reached.
fix
Refer to the official documentation and release notes for each update. Pinning exact versions (e.g., `"rozenite-graphql-client-devtool": "0.0.7"`) is recommended to avoid unexpected breaking changes in early versions.
affects: >=0.0.1
Upgrade
Version history
0.0.7latest on npm
Audit
Dependencies
reactrequiredPeer dependency required for any React Native application using this devtool.
react-nativerequiredPeer dependency required as this is a React Native specific devtool.
@apollo/clientoptionalRequired for integration with Apollo Client, which is currently the only supported GraphQL client.
graphqloptionalRequired by @apollo/client for GraphQL parsing and schema definition.
Agent activity
8 hits · last 30 days
node
6
OpenAI (training)
1
Resources
rozenite-graphql-client-devtool — npm install rozenite-graphql-client-devtool · libregistry