I am just wondering if there is a better approach ...
# suitescript
a
I am just wondering if there is a better approach to do this
e
You can use the
N/xml
module
and potentially the
N/render
module
An example from my
Rendering PDFs with SuiteScript
cookbook:
Module that pulls an XML Template from the File Cabinet and merges transaction data into the template. You can render as XML instead of PDF.
The template file itself.
a
Thanks a lot, I will review these
s
there is also the library
JSONIX
if you have XML schema for the desired output you can even auto-generate mappings (js to/from xml) with jsonix
r
Can JSONIX work server side in NS?
s
Yes, though I had to modify it a bit to get it working with SS2.x