Skip to content

code4fukui/XML

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

XML (xml2json, json2xml)

import { XML } from "https://js.sabae.cc/XML.js";

const json = XML.toJSON("<xml att='abc'><tag>text</tag></xml>");
console.log(json); // { xml: { att: "abc", tag: { "#text": "text" } } }

const xml = XML.stringify({ xml: { att: "abc", tag: { "#text": "text" } } });
console.log(xml);

dependency

Releases

No releases published

Packages

No packages published