CtrlK
BlogDocsLog inGet started
Tessl Logo

tessl/npm-xml2json

Converts XML to JSON and vice-versa using node-expat parser

Overall
score

93%

Overview
Eval results
Files

rubric.jsonevals/scenario-10/

{
  "context": "Evaluates whether the solution uses xml2json correctly to parse manifest XML with whitespace trimming and non-reversible text collapsing. Checks that options and outputs rely on xml2json features instead of manual string handling.",
  "type": "weighted_checklist",
  "checklist": [
    {
      "name": "toJson object output",
      "description": "Uses xml2json.toJson (or equivalent import) with object output enabled to return plain JavaScript objects instead of JSON strings before processing the manifest.",
      "max_score": 20
    },
    {
      "name": "Trim option",
      "description": "Enables or preserves the xml2json trim behavior (default true) so leading and trailing whitespace in text nodes is stripped without manual string cleanup.",
      "max_score": 25
    },
    {
      "name": "Reversible off",
      "description": "Keeps reversible mode disabled when calling xml2json.toJson so text nodes collapse to primitive strings rather than $t-wrapped objects.",
      "max_score": 25
    },
    {
      "name": "Collapsed text values",
      "description": "Ensures parsed fields like status, message, and package notes are read directly from collapsed text values (no $t or alternateTextNode keys) produced by xml2json.",
      "max_score": 15
    },
    {
      "name": "Whitespace-only nodes",
      "description": "Relies on xml2json trimming to ignore indentation-only whitespace nodes instead of manually filtering nodes after parsing.",
      "max_score": 15
    }
  ]
}

Install with Tessl CLI

npx tessl i tessl/npm-xml2json

tile.json