<div dir="ltr">I don't think that this SAI is like anyone else's.  That's an issue. Here's a sample that is currenting producing pretty good XML (missing X3D element attributes, I know).<div><br></div><div>The main feature I've added is parameter type-checking.</div><div><br></div><div>That helps a lot, but requires addition of shim field objects.</div><div><br></div><div>Suggestions on how to remove shim objects welcome.  My guess is mixins, but I've never done mixins.</div><div><br></div><div>John</div><div><div>============================================</div><div>"use strict"<br><br>import fs from 'fs'<br><br>import { meta, head, Scene, X3D,  Transform, Group, Material, Shape, Box, Appearance } from './x3d.js';<br>import { MFNode, SFColor, SFVec3f, SFString, SFNode, SFRotation } from './x3d.js';<br><br><br>var x3d = new X3D({<br>        head : new SFNode(new head({<br>                meta : new MFNode([<br>                        new meta({<br>                                name : new SFString("John W"),<br>                                content : new SFString("Carlson, I")<br>                        }),<br>                        new meta({<br>                                name : new SFString("John A"),<br>                                content : new SFString("Carlson, II")<br>                        }),<br>                        new meta({<br>                                name : new SFString("John R"),<br>                                content : new SFString("Carlson, III")<br>                        })<br>                ])<br>        })),<br>        Scene : new SFNode(new Scene({<br>                children : new MFNode([<br>                        new Shape({<br>                                appearance : new SFNode(new Appearance({<br>                                        material : new SFNode(new Material({<br>                                                diffuseColor : new SFColor([1, 0, 0])<br>                                        }))<br>                                })),<br>                                geometry : new SFNode(new Box({}))<br>                        }),<br>                        new Transform({<br>                                translation : new SFVec3f([1, 2, 3]),<br>                                scale: new SFVec3f([4, 5, 6]),<br>                                rotation: new SFRotation([7, 8, 9, 3.14])<br>                        })<br>                ])<br>        }))<br>});<br>console.log(x3d.toXMLNode());<br><div><div><br></div><div>==========================================</div><div><br></div><div>The x3d.js ES6 library is required:</div><div><br></div><div><a href="https://github.com/coderextreme/es6x3d/blob/master/x3d.js">https://github.com/coderextreme/es6x3d/blob/master/x3d.js</a>  <br></div><div><br></div><div>(download it)</div><div><br></div><div>Maybe someone can suggest how to serve this file from github in the above app.</div><div><br></div><div>Thanks,</div><div><br></div><div>John</div><div><br></div></div></div></div></div>