- From: Toby A Inkster <tai@g5n.co.uk>
- Date: Mon, 15 Dec 2008 21:22:50 +0000
- To: JSON Schema <json-schema@googlegroups.com>, Semantic Web <semantic-web@w3.org>, public-grddl-wg@w3.org
Here's a sketch of an idea, porting GRDDL from XML to JSON: http://buzzword.org.uk/2008/jsonGRDDL/spec I'm about half way to a full implementation, but in the mean time the following works already: <html> <script src="http://buzzword.org.uk/2008/jsonGRDDL/jsonobject" type="text/javascript"></script> <script src="http://buzzword.org.uk/2008/jsonGRDDL/jsont-sample" type="text/javascript"></script> <script type="text/javascript"> var joe = { "name" : "Joe Bloggs" , "mbox" : "joe@example.net" }; var jane = { "name" : "Jane Doe" , "mbox" : "jane@example.net" }; var group = { "people" : [ joe , jane ] }; window.alert(JSON.transform(jane, Person)); window.alert(JSON.transform(group, People)); </script> </html> -- Toby A Inkster <mailto:mail@tobyinkster.co.uk> <http://tobyinkster.co.uk>
Received on Monday, 15 December 2008 21:23:39 UTC