[x3d-public] Interesting JSON schema validation failure. What should I use for an regular expression for a uri for a Script.url field? (or uri's in general). I'd like to reject this or at least warn.
yottzumm at gmail.com
yottzumm at gmail.com
Sun May 7 07:33:36 PDT 2017
Failed C:/x3d-code/www.web3d.org/x3d/content/examples/Vrml2Sourcebook/Chapter30Scripts/Figure30_1ScriptSlidingBall.json
keyword: format
dataPath: X3D > Scene > -children > 3 > Group > -children > 8 > Script > @url > 0
value: "ecmascript: function set_fraction( fraction eventTime ) { value_changed[0] = fraction; value_changed[1] = 0.0; value_changed[2] = 0.0; }"
message: should match format "uri"
params: {"format":"uri"}
file: C:/x3d-code/www.web3d.org/x3d/content/examples/Vrml2Sourcebook/Chapter30Scripts/Figure30_1ScriptSlidingBall.json
version: 3.0
As you can see, things are improving with Schema errors, at least in the console. I’m hoping that Alex will provide HTML integration and good console colored errors. Alex is a good sounding board for me.
I was able to repurpose some of my code for MFPath routes to get the value: out of the object. How do you like the dataPath format? I wanted to make it very explorer like. This is a new addition to X3DJSONLD.js code proper, instead of being a side project.
John
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://web3d.org/pipermail/x3d-public_web3d.org/attachments/20170507/62612c78/attachment-0001.html>
More information about the x3d-public
mailing list