graphql-apollo-client
Advanced tools
Comparing version 1.0.3 to 1.0.4
@@ -1,6 +0,6 @@ | ||
const { configureClient, gql } = require('./index'); | ||
const { configureClient, gql } = require('graphql-apollo-client'); | ||
const GRAPHQL_ENDPOINT = "https://api.ecomon.no"; | ||
const GRAPHQL_ENDPOINT_WS = "wss://api.ecomon.no"; | ||
const TOKEN = "Bearer intermediary-api-key_858bef2f-5b67-49b2-b7e0-c07a093f98be"; | ||
const GRAPHQL_ENDPOINT = 'https://api.ecomon.no'; | ||
const GRAPHQL_ENDPOINT_WS = 'wss://api.ecomon.no'; | ||
const TOKEN = 'Bearer intermediary-api-key_858bef2f-5b67-49b2-b7e0-c07a093f98be'; | ||
@@ -10,7 +10,5 @@ const client = configureClient({ | ||
wsEndpoint: GRAPHQL_ENDPOINT_WS, | ||
bearerToken: TOKEN | ||
}) | ||
bearerToken: TOKEN, | ||
}); | ||
// Test subscription | ||
@@ -27,3 +25,3 @@ client | ||
`, | ||
variables: {} | ||
variables: {}, | ||
}) | ||
@@ -33,4 +31,6 @@ .subscribe({ | ||
console.log(data); | ||
}, | ||
error(err) { | ||
console.log(err) | ||
} | ||
}); | ||
}) |
@@ -9,4 +9,4 @@ const { InMemoryCache } = require("apollo-cache-inmemory"); | ||
const { getMainDefinition } = require("apollo-utilities"); | ||
const fetch = (...args) => | ||
import("node-fetch").then(({ default: fetch }) => fetch(...args)); | ||
// const fetch = (...args) => | ||
// import("node-fetch").then(({ default: fetch }) => fetch(...args)); | ||
@@ -35,3 +35,3 @@ /** | ||
uri: httpEndpoint, | ||
fetch: fetch, | ||
// fetch: fetch, | ||
headers: { | ||
@@ -38,0 +38,0 @@ Authorization: bearerToken |
{ | ||
"name": "graphql-apollo-client", | ||
"version": "1.0.3", | ||
"version": "1.0.4", | ||
"main": "index.js", | ||
"license": "MIT", | ||
"repository":"https://github.com/mxshahan/graphql-apollo-client.git", | ||
"repository": "https://github.com/mxshahan/graphql-apollo-client.git", | ||
"dependencies": { | ||
@@ -27,4 +27,8 @@ "apollo-cache-inmemory": "1.6.6", | ||
}, | ||
"keywords": [" nodejs", "graphql", " javascript"], | ||
"keywords": [ | ||
" nodejs", | ||
"graphql", | ||
" javascript" | ||
], | ||
"description": "" | ||
} |
Network access
Supply chain riskThis module accesses the network.
Found 1 instance in 1 package
5089
133
0