Comparing version 3.5.6 to 3.5.7
import { UnformattedClosureSyntaxTree, UnformattedMethodSyntaxTree, UnformattedNonGremlinSyntaxTree, UnformattedStringSyntaxTree, UnformattedTraversalSyntaxTree, UnformattedWordSyntaxTree } from './types'; | ||
declare type GremlinOnelinerSyntaxTree = UnformattedNonGremlinSyntaxTree | Pick<UnformattedTraversalSyntaxTree, 'type' | 'steps'> | Pick<UnformattedMethodSyntaxTree, 'type' | 'method' | 'arguments'> | Pick<UnformattedClosureSyntaxTree, 'type' | 'method' | 'closureCodeBlock'> | Pick<UnformattedStringSyntaxTree, 'type' | 'string'> | Pick<UnformattedWordSyntaxTree, 'type' | 'word'>; | ||
type GremlinOnelinerSyntaxTree = UnformattedNonGremlinSyntaxTree | Pick<UnformattedTraversalSyntaxTree, 'type' | 'steps'> | Pick<UnformattedMethodSyntaxTree, 'type' | 'method' | 'arguments'> | Pick<UnformattedClosureSyntaxTree, 'type' | 'method' | 'closureCodeBlock'> | Pick<UnformattedStringSyntaxTree, 'type' | 'string'> | Pick<UnformattedWordSyntaxTree, 'type' | 'word'>; | ||
declare const recreateQueryOnelinerFromSyntaxTree: (localIndentation?: number) => (syntaxTree: GremlinOnelinerSyntaxTree) => string; | ||
export default recreateQueryOnelinerFromSyntaxTree; |
@@ -1,2 +0,2 @@ | ||
export declare type GremlintUserConfig = { | ||
export type GremlintUserConfig = { | ||
indentation: number; | ||
@@ -6,3 +6,3 @@ maxLineLength: number; | ||
}; | ||
export declare type GremlintInternalConfig = { | ||
export type GremlintInternalConfig = { | ||
globalIndentation: number; | ||
@@ -24,7 +24,7 @@ localIndentation: number; | ||
} | ||
export declare type UnformattedNonGremlinSyntaxTree = { | ||
export type UnformattedNonGremlinSyntaxTree = { | ||
type: TokenType.NonGremlinCode; | ||
code: string; | ||
}; | ||
export declare type UnformattedTraversalSyntaxTree = { | ||
export type UnformattedTraversalSyntaxTree = { | ||
type: TokenType.Traversal; | ||
@@ -34,3 +34,3 @@ steps: UnformattedSyntaxTree[]; | ||
}; | ||
export declare type UnformattedMethodSyntaxTree = { | ||
export type UnformattedMethodSyntaxTree = { | ||
type: TokenType.Method; | ||
@@ -40,8 +40,8 @@ method: UnformattedSyntaxTree; | ||
}; | ||
export declare type UnformattedClosureLineOfCode = { | ||
export type UnformattedClosureLineOfCode = { | ||
lineOfCode: string; | ||
relativeIndentation: number; | ||
}; | ||
export declare type UnformattedClosureCodeBlock = UnformattedClosureLineOfCode[]; | ||
export declare type UnformattedClosureSyntaxTree = { | ||
export type UnformattedClosureCodeBlock = UnformattedClosureLineOfCode[]; | ||
export type UnformattedClosureSyntaxTree = { | ||
type: TokenType.Closure; | ||
@@ -51,18 +51,18 @@ method: UnformattedSyntaxTree; | ||
}; | ||
export declare type UnformattedStringSyntaxTree = { | ||
export type UnformattedStringSyntaxTree = { | ||
type: TokenType.String; | ||
string: string; | ||
}; | ||
export declare type UnformattedWordSyntaxTree = { | ||
export type UnformattedWordSyntaxTree = { | ||
type: TokenType.Word; | ||
word: string; | ||
}; | ||
export declare type UnformattedSyntaxTree = UnformattedMethodSyntaxTree | UnformattedClosureSyntaxTree | UnformattedStringSyntaxTree | UnformattedWordSyntaxTree | UnformattedTraversalSyntaxTree | UnformattedNonGremlinSyntaxTree; | ||
export declare type FormattedNonGremlinSyntaxTree = UnformattedNonGremlinSyntaxTree & { | ||
export type UnformattedSyntaxTree = UnformattedMethodSyntaxTree | UnformattedClosureSyntaxTree | UnformattedStringSyntaxTree | UnformattedWordSyntaxTree | UnformattedTraversalSyntaxTree | UnformattedNonGremlinSyntaxTree; | ||
export type FormattedNonGremlinSyntaxTree = UnformattedNonGremlinSyntaxTree & { | ||
width: number; | ||
}; | ||
export declare type GremlinStepGroup = { | ||
export type GremlinStepGroup = { | ||
steps: FormattedSyntaxTree[]; | ||
}; | ||
export declare type FormattedTraversalSyntaxTree = { | ||
export type FormattedTraversalSyntaxTree = { | ||
type: TokenType.Traversal; | ||
@@ -75,3 +75,3 @@ steps: UnformattedSyntaxTree[]; | ||
}; | ||
export declare type FormattedMethodSyntaxTree = { | ||
export type FormattedMethodSyntaxTree = { | ||
type: TokenType.Method; | ||
@@ -87,3 +87,3 @@ method: FormattedSyntaxTree; | ||
}; | ||
declare type FormattedClosureLineOfCode = { | ||
type FormattedClosureLineOfCode = { | ||
lineOfCode: string; | ||
@@ -93,4 +93,4 @@ relativeIndentation: number; | ||
}; | ||
declare type FormattedClosureCodeBlock = FormattedClosureLineOfCode[]; | ||
export declare type FormattedClosureSyntaxTree = { | ||
type FormattedClosureCodeBlock = FormattedClosureLineOfCode[]; | ||
export type FormattedClosureSyntaxTree = { | ||
type: TokenType.Closure; | ||
@@ -104,3 +104,3 @@ method: FormattedSyntaxTree; | ||
}; | ||
export declare type FormattedStringSyntaxTree = { | ||
export type FormattedStringSyntaxTree = { | ||
type: TokenType.String; | ||
@@ -111,3 +111,3 @@ string: string; | ||
}; | ||
export declare type FormattedWordSyntaxTree = { | ||
export type FormattedWordSyntaxTree = { | ||
type: TokenType.Word; | ||
@@ -120,4 +120,4 @@ word: string; | ||
}; | ||
export declare type FormattedSyntaxTree = FormattedTraversalSyntaxTree | FormattedMethodSyntaxTree | FormattedClosureSyntaxTree | FormattedStringSyntaxTree | FormattedWordSyntaxTree | FormattedNonGremlinSyntaxTree; | ||
export declare type GremlinSyntaxTreeFormatter = (config: GremlintInternalConfig) => (syntaxTree: UnformattedSyntaxTree) => FormattedSyntaxTree; | ||
export type FormattedSyntaxTree = FormattedTraversalSyntaxTree | FormattedMethodSyntaxTree | FormattedClosureSyntaxTree | FormattedStringSyntaxTree | FormattedWordSyntaxTree | FormattedNonGremlinSyntaxTree; | ||
export type GremlinSyntaxTreeFormatter = (config: GremlintInternalConfig) => (syntaxTree: UnformattedSyntaxTree) => FormattedSyntaxTree; | ||
export {}; |
{ | ||
"name": "gremlint", | ||
"version": "3.5.6", | ||
"version": "3.5.7", | ||
"description": "Linter/code formatter for Gremlin", | ||
@@ -39,4 +39,5 @@ "main": "lib/index.js", | ||
"@types/jest": "^27.5.0", | ||
"@types/node": "^20.4.5", | ||
"jest": "^26.6.1", | ||
"prettier": "^2.7.1", | ||
"prettier": "^3.0.0", | ||
"ts-jest": "^26.4.2", | ||
@@ -51,4 +52,4 @@ "tslint": "^6.1.3", | ||
"engines": { | ||
"node": ">=10" | ||
"node": ">=16" | ||
} | ||
} |
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
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a 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
Unidentified License
License(Experimental) Something that seems like a license was found, but its contents could not be matched with a known license.
Found 1 instance in 1 package
0
100
105283
8
49
1