Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@graphitation/apollo-mock-client

Package Overview
Dependencies
Maintainers
4
Versions
48
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@graphitation/apollo-mock-client - npm Package Compare versions

Comparing version 0.7.0 to 0.8.0

29

CHANGELOG.md
# Change Log - @graphitation/apollo-mock-client
This log was last generated on Wed, 24 Nov 2021 13:22:06 GMT and should not be manually modified.
This log was last generated on Mon, 13 Dec 2021 16:41:04 GMT and should not be manually modified.
<!-- Start content -->
## 0.7.0
## 0.8.0
Wed, 24 Nov 2021 13:22:06 GMT
Mon, 13 Dec 2021 16:41:04 GMT
### Minor changes
- Allow cache config of mock client (eloy.de.enige@gmail.com)
- Support ESM in distro packages (mnovikov@microsoft.com)
### Patches
- Bump @graphitation/graphql-js-operation-payload-generator to v0.6.0 (mnovikov@microsoft.com)
- Bump @graphitation/graphql-js-tag to v0.6.0 (mnovikov@microsoft.com)
## 0.6.11
Tue, 26 Oct 2021 21:09:29 GMT
### Patches
- Bump @graphitation/graphql-js-tag to v0.5.5 (modevold@microsoft.com)
## 0.6.10
Tue, 26 Oct 2021 12:46:12 GMT
### Patches
- Align graphql dependency to version ^15.0.0 across packages (modevold@microsoft.com)
## 0.6.9

@@ -16,0 +37,0 @@

6

lib/index.d.ts

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

import { ApolloClient, NormalizedCacheObject, InMemoryCacheConfig } from "@apollo/client";
import { ApolloClient, NormalizedCacheObject } from "@apollo/client";
import { DocumentNode, ExecutionResult, GraphQLSchema } from "graphql";

@@ -90,6 +90,4 @@ export interface RequestDescriptor<Node = DocumentNode> {

}
export declare function createMockClient(schema: GraphQLSchema, options?: {
cache?: InMemoryCacheConfig;
}): ApolloMockClient;
export declare function createMockClient(schema: GraphQLSchema): ApolloMockClient;
export {};
//# sourceMappingURL=index.d.ts.map

@@ -7,16 +7,2 @@ var __create = Object.create;

var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
var __getOwnPropSymbols = Object.getOwnPropertySymbols;
var __propIsEnum = Object.prototype.propertyIsEnumerable;
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, {enumerable: true, configurable: true, writable: true, value}) : obj[key] = value;
var __objSpread = (a, b) => {
for (var prop in b || (b = {}))
if (__hasOwnProp.call(b, prop))
__defNormalProp(a, prop, b[prop]);
if (__getOwnPropSymbols)
for (var prop of __getOwnPropSymbols(b)) {
if (__propIsEnum.call(b, prop))
__defNormalProp(a, prop, b[prop]);
}
return a;
};
var __markAsModule = (target) => __defProp(target, "__esModule", {value: true});

@@ -180,3 +166,3 @@ var __export = (target, all) => {

}
function createMockClient(schema, options) {
function createMockClient(schema) {
const possibleTypes = {};

@@ -192,7 +178,6 @@ Object.keys(schema.getTypeMap()).forEach((typeName) => {

return Object.assign(new import_client.ApolloClient({
cache: new import_client.InMemoryCache(__objSpread(__objSpread({
addTypename: true
}, options == null ? void 0 : options.cache), {
possibleTypes
})),
cache: new import_client.InMemoryCache({
possibleTypes,
addTypename: false
}),
link

@@ -199,0 +184,0 @@ }), {

@@ -5,4 +5,4 @@ {

"license": "MIT",
"version": "0.7.0",
"main": "./src/index.ts",
"version": "0.8.0",
"main": "./lib/index.js",
"scripts": {

@@ -16,5 +16,5 @@ "build": "monorepo-scripts build",

"devDependencies": {
"@apollo/client": "^3.4.13",
"@graphitation/graphql-js-tag": "^0.5.4",
"@graphitation/graphql-js-operation-payload-generator": "^0.5.9",
"@apollo/client": "^3.3.15",
"@graphitation/graphql-js-tag": "^0.6.0",
"@graphitation/graphql-js-operation-payload-generator": "^0.6.0",
"@types/invariant": "^2.2.34",

@@ -24,3 +24,3 @@ "@types/jest": "^26.0.22",

"@types/react-test-renderer": "^17.0.1",
"graphql": "^15.5.0",
"graphql": "^15.0.0",
"monorepo-scripts": "*",

@@ -31,4 +31,4 @@ "react": "^17.0.2",

"peerDependencies": {
"@apollo/client": "^3.4.13",
"graphql": "^15.5.0"
"@apollo/client": "^3.3.0",
"graphql": "^15.0.0"
},

@@ -39,6 +39,12 @@ "dependencies": {

"publishConfig": {
"main": "./lib/index",
"types": "./lib/index.d.ts",
"access": "public"
},
"types": "./lib/index.d.ts",
"module": "./lib/index.mjs",
"exports": {
".": {
"import": "./lib/index.mjs",
"require": "./lib/index.js"
}
}
}

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