gremlint
Version:
Linter/code formatter for Gremlin
5 lines (4 loc) • 766 B
TypeScript
import { UnformattedClosureSyntaxTree, UnformattedMethodSyntaxTree, UnformattedNonGremlinSyntaxTree, UnformattedStringSyntaxTree, UnformattedTraversalSyntaxTree, UnformattedWordSyntaxTree } from './types';
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;