This is a preview version of Kit’n’TOS – public service for TOSes and other TL;DRs. Main feature – every section of every doc can be ‘kittenized’ by end users. More kittens – more friendly doc.
###Description
Kit‘n‘TOS is pure javascript project. User puts URL of external HTML page with TL;DR, server fetches the page, parses it, flattens, and then allows each section to be rated. Rating is kitten-based: for nice texts – nifty kittens, for awkward ones – angry kittens. There are 5 grades. Also user can comment his decision – 50 chars more.
Comments and kittens are shown aside text – so looking into kitns‘ faces it’s easy to estimate how friendly doc is.
The main challenge was to create parser, that flattens sometimes very spriggy and strange DOM structure of TL;DRs. Parser was created using browser IDE of cloudwall.me and ported to node.js. It uses mostly jQuery – so porting per se took very little time.
We use two DBs – Mongo to keep sessions (users can log in using Twi, Github or FB) and CouchDB to persist fetched docs and votes.
jQuery.my plugin is used to render and manage UI.
IDE, fragment of parser testbench.
###APIs and libs
We used:
- Koding.com environment to run project
- Hackathon Starter – cozy environment for node.js apps
- cloudwall.me IDE to develop UI
- node.js – for everything
- Sugar to make JS even more sweet
- CouchDB – for docs and nice indexed map-reduce
- jQuery.my plugin to render UI
- jQuery to manipulate DOM