How to output JSON with swig in nodejs