🚀 Big News: Socket Acquires Coana to Bring Reachability Analysis to Every Appsec Team.Learn more
Socket
Book a DemoInstallSign in
Socket

graphql-language-service

Package Overview
Dependencies
Maintainers
14
Versions
257
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

graphql-language-service - npm Package Compare versions

Comparing version

to
5.3.2-canary-25ac0f5f.0

4

dist/utils/getOperationFacts.js

@@ -27,5 +27,3 @@ "use strict";

}
catch (_a) {
return;
}
catch (_a) { }
}

@@ -32,0 +30,0 @@ exports.default = getOperationFacts;

@@ -23,7 +23,5 @@ import { parse, visit } from 'graphql';

}
catch (_a) {
return;
}
catch (_a) { }
}
export const getQueryFacts = getOperationFacts;
//# sourceMappingURL=getOperationFacts.js.map
{
"name": "graphql-language-service",
"version": "5.3.1",
"version": "5.3.2-canary-25ac0f5f.0",
"description": "The official, runtime independent Language Service for GraphQL",

@@ -10,3 +10,3 @@ "contributors": [

"type": "git",
"url": "http://github.com/graphql/graphiql",
"url": "https://github.com/graphql/graphiql",
"directory": "packages/graphql-language-service"

@@ -13,0 +13,0 @@ },

@@ -35,3 +35,3 @@ # `graphql-language-service`

A standalone online, immutable, dependency-free parser for
[GraphQL](http://graphql.org/), used by the LSP interface methods
[GraphQL](https://graphql.org), used by the LSP interface methods

@@ -38,0 +38,0 @@ ## Utils

@@ -108,21 +108,23 @@ /**

// and validate the entire completion object - kinds, documentation, etc
const response = { label: suggestion.label } as CompletionItem;
const response: CompletionItem = { label: suggestion.label };
if (suggestion.detail) {
response.detail = String(suggestion.detail);
response.detail = suggestion.detail;
}
if (suggestion.insertText && !options?.ignoreInsert) {
response.insertText = suggestion.insertText;
if (!options?.ignoreInsert) {
if (suggestion.insertText) {
response.insertText = suggestion.insertText;
}
if (suggestion.insertTextFormat) {
response.insertTextFormat = suggestion.insertTextFormat;
}
if (suggestion.command) {
response.command = suggestion.command;
}
if (suggestion.labelDetails) {
response.labelDetails = suggestion.labelDetails;
}
}
if (suggestion.insertTextFormat && !options?.ignoreInsert) {
response.insertTextFormat = suggestion.insertTextFormat;
}
if (suggestion.command && !options?.ignoreInsert) {
response.command = suggestion.command;
}
if (suggestion.documentation?.length) {
response.documentation = suggestion.documentation;
}
if (suggestion.labelDetails && !options?.ignoreInsert) {
response.labelDetails = suggestion.labelDetails;
}

@@ -132,2 +134,3 @@ return response;

}
describe('with Operation types', () => {

@@ -134,0 +137,0 @@ const expectedDirectiveSuggestions = [

@@ -93,5 +93,3 @@ /**

};
} catch {
return;
}
} catch {}
}

@@ -98,0 +96,0 @@

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