New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@rtk-query/graphql-request-base-query

Package Overview
Dependencies
Maintainers
4
Versions
9
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@rtk-query/graphql-request-base-query - npm Package Compare versions

Comparing version 2.2.0 to 2.3.0

16

dist/GraphqlBaseQueryTypes.d.ts

@@ -1,7 +0,7 @@

import type { BaseQueryApi } from '@reduxjs/toolkit/dist/query/baseQueryTypes';
import type { BaseQueryApi } from '@reduxjs/toolkit/query';
import type { GraphQLClient, RequestOptions, RequestDocument, ClientError } from 'graphql-request';
export declare type Document = RequestDocument;
export declare type RequestHeaders = RequestOptions['requestHeaders'];
export declare type PrepareHeaders = (headers: Headers, api: Pick<BaseQueryApi, 'getState' | 'endpoint' | 'type' | 'forced' | 'extra'>) => MaybePromise<Headers>;
export declare type ErrorResponse = {
export type Document = RequestDocument;
export type RequestHeaders = RequestOptions['requestHeaders'];
export type PrepareHeaders = (headers: Headers, api: Pick<BaseQueryApi, 'getState' | 'endpoint' | 'type' | 'forced' | 'extra'>) => MaybePromise<Headers>;
export type ErrorResponse = {
message: string;

@@ -11,3 +11,3 @@ stack: string;

};
export declare type GraphqlRequestBaseQueryArgs<E = ErrorResponse> = ({
export type GraphqlRequestBaseQueryArgs<E = ErrorResponse> = ({
url: string;

@@ -21,3 +21,3 @@ } | {

};
export declare type QueryReturnValue<T = unknown, E = unknown, M = unknown> = {
export type QueryReturnValue<T = unknown, E = unknown, M = unknown> = {
error: E;

@@ -31,2 +31,2 @@ data?: undefined;

};
export declare type MaybePromise<T> = T | PromiseLike<T>;
export type MaybePromise<T> = T | PromiseLike<T>;

@@ -8,2 +8,2 @@ import type { BaseQueryFn } from '@reduxjs/toolkit/query';

variables?: any;
}, unknown, E, Partial<Pick<ClientError, "request" | "response">>, {}>;
}, unknown, E, Partial<Pick<ClientError, "request" | "response">>>;
{
"name": "@rtk-query/graphql-request-base-query",
"version": "2.2.0",
"version": "2.3.0",
"author": {

@@ -10,2 +10,6 @@ "name": "Lenz Weber",

"license": "MIT",
"repository": {
"type": "git",
"url": "git+https://github.com/reduxjs/redux-toolkit.git"
},
"type": "module",

@@ -20,6 +24,7 @@ "source": "src/index.ts",

"prepack": "rimraf dist/*; yarn build",
"dev": "microbundle watch"
"dev": "microbundle watch",
"test": "true"
},
"dependencies": {
"graphql-request": "^4.0.0"
"graphql-request": "^4.0.0 || ^5.0.0 || ^6.0.0"
},

@@ -31,3 +36,3 @@ "peerDependencies": {

"devDependencies": {
"@reduxjs/toolkit": "^1.6.0",
"@reduxjs/toolkit": "^1.6.0 || ^2.0.0",
"graphql": "^16.5.0",

@@ -34,0 +39,0 @@ "microbundle": "^0.13.3",

@@ -1,2 +0,2 @@

import type { BaseQueryApi } from '@reduxjs/toolkit/dist/query/baseQueryTypes'
import type { BaseQueryApi } from '@reduxjs/toolkit/query'
import type {

@@ -3,0 +3,0 @@ GraphQLClient,

import { isPlainObject } from '@reduxjs/toolkit'
import type { BaseQueryFn } from '@reduxjs/toolkit/query'
import type { DocumentNode } from 'graphql'
import { GraphQLClient, ClientError } from 'graphql-request'
import { GraphQLClient, ClientError, RequestOptions } from 'graphql-request'
import type {

@@ -46,3 +46,3 @@ ErrorResponse,

variables,
signal,
signal: signal as unknown as RequestOptions['signal'],
requestHeaders: preparedHeaders,

@@ -56,6 +56,6 @@ }),

const customErrors =
options.customErrors ?? (() => ({ name, message, stack }));
const customErrors =
options.customErrors ?? (() => ({ name, message, stack }))
const customizedErrors = customErrors(error) as E;
const customizedErrors = customErrors(error) as E

@@ -62,0 +62,0 @@ return { error: customizedErrors, meta: { request, response } }

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc