<html><head><meta http-equiv="Content-Type" content="text/html charset=us-ascii" /></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class="">Very nice! Very useful for my unit tests.<br>
<br>
Indeed, my node.js project produced X3D files, then I finally decided to produce X3D json natively. But I missed a way to check if json generated was acceptable.<br>
<br>
Now, thanks to you, I can convert (revert) json result to X3D to check if it match with X3D I got before.<br>
<br>
Great!<br><br><div class="gmail_quote">Le 10 décembre 2015 18:50:35 UTC+01:00, John Carlson <yottzumm@gmail.com> a écrit :<blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
As part of my loader, I can convert JSON to XML. If you want to check what the JSON is likely producing (but not positively, x3dom produces more or fails) in terms of DOM, you can run this program, json2x3d.js. It requires node.js, but you should be able to convert it for use in the browser (or just use my loader). The source code is here: <a href="https://raw.githubusercontent.com/coderextreme/X3DJSONLD/master/json2x3d.js" class="">https://raw.githubusercontent.com/coderextreme/X3DJSONLD/master/json2x3d.js</a><div class=""><br class="" /></div><div class="">You can run it like</div><div class=""><br class="" /></div><div class="">node json2x3d.js < file.son > file.x3d</div><div class=""><br class="" /></div><div class="">Note that this overwrites file.x3d</div><p style="margin-top: 2.5em; margin-bottom: 1em; border-bottom: 1px solid #000"></p><pre class="k9mail"><hr /><br />x3d-public mailing list<br />x3d-public@web3d.org<br /><a
href="http://web3d.org/mailman/listinfo/x3d-public_web3d.org">http://web3d.org/mailman/listinfo/x3d-public_web3d.org</a><br /></pre></blockquote></div><br>
clement@igonet.fr</body></html>