W3C home > Mailing lists > Public > semantic-web@w3.org > December 2008

Draft jsonGRDDL spec - bringing JSON to the SemWeb party!

From: Toby A Inkster <tai@g5n.co.uk>
Date: Mon, 15 Dec 2008 21:22:50 +0000
Message-Id: <FDD96D09-8765-40B6-8542-A8EBF93FAADC@g5n.co.uk>
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:37 GMT

This archive was generated by hypermail 2.3.1 : Tuesday, 26 March 2013 21:45:26 GMT