Function determineInputSchema
has a Cognitive Complexity of 10 (exceeds 5 allowed). Consider refactoring.
private determineInputSchema(schemaPath: string | undefined): string {
const bundleDefined = has(this.project.config, 'extensions.prepare-bundle.output')
const oldBundleDefined = has(this.project.config, 'extensions.bundle.output')
if (!schemaPath) {
Function determineBindingOutputPath
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring.
private determineBindingOutputPath(extension: string) {
let outputPath: string
if (this.argv.output) {
outputPath = path.join(this.argv.output, `${this.projectName}.${extension}`)
} else if (has(this.project.config, `extensions.binding.output`)) {
Function determineBundleOutputPath
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring.
private determineBundleOutputPath() {
let outputPath: string
if (this.argv.output) {
outputPath = path.join(this.argv.output, `${this.projectName}.graphql`)
} else if (has(this.project.config, `extensions.bundle`)) {
Function getProjectConfig
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring.
private getProjectConfig(): { [name: string]: GraphQLProjectConfig } {
let projects: { [name: string]: GraphQLProjectConfig } | undefined
if (this.argv.project) {
if (Array.isArray(this.argv.project)) {
projects = {}