UNPKG

@unisnips/jetbrains

Version:

Utilities for generating JetBrains live templates in unisnips project

17 lines (16 loc) 577 B
export declare type XMLAttribute = { name: string; value: string | boolean | number; }; export declare type XMLNode = { tagName: string; attributes: XMLAttribute[]; children?: XMLNode[]; }; export declare function indent(str: string, cols: number): string; export declare function nodeTreeToXml(root: XMLNode, level?: number): string; export declare function attr(name: string, value: string | boolean): { name: string; value: string | boolean; }; export declare function makeTag(name: string, attrs: XMLAttribute[], children?: XMLNode[]): XMLNode;