Using Mustach.js for mapping XML

Could anyone point me in the right direction for using mustache.js to send values to the template from remote XML as opposed to JSON? I’ve seen the stack subject here: template engine - Is it possible with mustache.js to map xml and use xpath routes like {{/root/Customer}}? - Stack Overflow
and it is marked correct but I don’t quite understand where to add this code within a TVML context. Anyone have any insight on that? Thanks a ton in advance.