@graphql-toolkit/code-file-loader
Advanced tools
Comparing version 0.7.2-alpha-0c3da6c.0 to 0.7.2-alpha-5567589.7
import { Source } from 'graphql'; | ||
export interface ExtractOptions { | ||
tagPluck?: { | ||
modules?: Array<{ | ||
name: string; | ||
identifier?: string; | ||
}>; | ||
magicComment?: string; | ||
globalIdentifier?: string; | ||
}; | ||
pluckConfig?: GraphQLTagPluckOptions; | ||
} | ||
interface GraphQLTagPluckOptions { | ||
modules?: Array<{ | ||
name: string; | ||
identifier?: string; | ||
}>; | ||
gqlMagicComment?: string; | ||
globalGqlIdentifierName?: string; | ||
} | ||
export declare function extractDocumentStringFromCodeFile(source: Source, options?: ExtractOptions): Promise<string | void>; | ||
export {}; |
@@ -6,3 +6,3 @@ "use strict"; | ||
function calculateOptions(options) { | ||
if (!options || !options.tagPluck) { | ||
if (!options || !options.pluckConfig) { | ||
return {}; | ||
@@ -17,3 +17,3 @@ } | ||
return Object.keys(keyMap).reduce((prev, curr) => { | ||
const value = options.tagPluck[curr]; | ||
const value = options.pluckConfig[curr]; | ||
if (value) { | ||
@@ -20,0 +20,0 @@ return { |
import { Source } from 'graphql'; | ||
export interface ExtractOptions { | ||
tagPluck?: { | ||
modules?: Array<{ | ||
name: string; | ||
identifier?: string; | ||
}>; | ||
magicComment?: string; | ||
globalIdentifier?: string; | ||
}; | ||
pluckConfig?: GraphQLTagPluckOptions; | ||
} | ||
interface GraphQLTagPluckOptions { | ||
modules?: Array<{ | ||
name: string; | ||
identifier?: string; | ||
}>; | ||
gqlMagicComment?: string; | ||
globalGqlIdentifierName?: string; | ||
} | ||
export declare function extractDocumentStringFromCodeFile(source: Source, options?: ExtractOptions): Promise<string | void>; | ||
export {}; |
import { parse } from 'graphql'; | ||
import { gqlPluckFromFile } from 'graphql-tag-pluck'; | ||
function calculateOptions(options) { | ||
if (!options || !options.tagPluck) { | ||
if (!options || !options.pluckConfig) { | ||
return {}; | ||
@@ -14,3 +14,3 @@ } | ||
return Object.keys(keyMap).reduce((prev, curr) => { | ||
const value = options.tagPluck[curr]; | ||
const value = options.pluckConfig[curr]; | ||
if (value) { | ||
@@ -17,0 +17,0 @@ return { |
{ | ||
"name": "@graphql-toolkit/code-file-loader", | ||
"version": "0.7.2-alpha-0c3da6c.0+0c3da6c", | ||
"version": "0.7.2-alpha-5567589.7+5567589", | ||
"description": "A set of utils for faster development of GraphQL tools", | ||
@@ -31,3 +31,3 @@ "repository": "git@github.com:dotansimha/graphql-toolkit.git", | ||
"dependencies": { | ||
"@graphql-toolkit/common": "0.7.2-alpha-0c3da6c.0+0c3da6c", | ||
"@graphql-toolkit/common": "0.7.2-alpha-5567589.7+5567589", | ||
"graphql-tag-pluck": "0.8.7", | ||
@@ -40,3 +40,3 @@ "is-valid-path": "0.1.1", | ||
}, | ||
"gitHead": "0c3da6c10a43f5625f318e77aab31dbad571966d" | ||
"gitHead": "55675890361a0f58d10bcbf0f38a8d798cc50186" | ||
} |
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
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Manifest confusion
Supply chain riskThis package has inconsistent metadata. This could be malicious or caused by an error when publishing the package.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Manifest confusion
Supply chain riskThis package has inconsistent metadata. This could be malicious or caused by an error when publishing the package.
Found 1 instance in 1 package
30558
411