JSON 2 HTML
Inspired by http://news.ycombinator.com/item?id=239735 I decided to create something that made it easier for me to get JSON objects into HTML so that I could quickly move onto styling.
JSON 2 HTML (json2html.js) allows for easy conversion of JSON objects into semantically meaningful HTML. Arrays are converted to Ordered Lists (OL) and objects are converted to Unordered Lists (UL) where each List Item (LI) has a class equal to the key of the value in the object. Strings are checked for urls which are automatically converted into links. Booleans, numbers and null are converted to strings. The result is then stored in a placeholder div. CSS is used to format the output.