diff --git a/index.d.ts b/index.d.ts new file mode 100644 index 0000000..49b4b83 --- /dev/null +++ b/index.d.ts @@ -0,0 +1,15 @@ +interface XMLElement { + name: string; + attributes: { + [name: string]: string; + }; + value: string; + children: XMLElement[]; +} + +export default class XMLParser { + constructor(); + public parseFromString(string: string): XMLElement; + public toString(xml: XMLElement): string; + public getElementsByTagName(tagName: string): XMLElement[]; +} \ No newline at end of file