Skip to content

Symetry breaking / strange loading behaviour #17

@niederlec

Description

@niederlec

This behaviour looks strange/unexpected, but I guess it is a limitation of the Google GData protocol.

var json = xmlMapping.load('<root>hello <child>!</child>you</root>');
console.log(json)
// => returns { root: { '$t': [ 'hello', 'you' ], child: { '$t': '!' } } }

var xml = xmlMapping.dump(json);
console.log(xml);
// => returns <root><child>!</child><:t><![CDATA[hello]]></:t><:t><![CDATA[you]]></:t></root>

Two major problems for me :

  • the order of XML nodes is not preserved
  • bad xml elements with empty namespace are generated

Any idea or solution ?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions