1.2.33 • Published 6 months ago

@types/xml-parser v1.2.33

Weekly downloads
6,029
License
MIT
Repository
github
Last release
6 months ago

Installation

npm install --save @types/xml-parser

Summary

This package contains type definitions for xml-parser (https://github.com/segmentio/xml-parser).

Details

Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/xml-parser.

index.d.ts

// Type definitions for xml-parser 1.2.1
// Project: https://github.com/segmentio/xml-parser
// Definitions by: Matt Frantz <https://github.com/mhfrantz>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped



declare function parse(xml: string): parse.Document;

declare namespace parse {
    export interface Document {
        declaration: Declaration;
        root: Node;
    }

    export interface Declaration {
        attributes: Attributes;
    }

    export interface Node {
        name: string;
        attributes: Attributes;
        children: Node[];
        content?: string | undefined;
    }

    export interface Attributes {
        [name: string]: string;
    }
}

export = parse;

Additional Details

  • Last updated: Fri, 02 Jul 2021 17:02:21 GMT
  • Dependencies: none
  • Global values: none

Credits

These definitions were written by Matt Frantz.