Chartly: build data visualisations in the browsers using puzzle pieces

Chartly.js is a web component that allows end users to create (‘program’) a chart using the Blockly visual programming environment. Charts are ‘compiled’ to a JSON specification for the chart. At run time, Chartly interprets the JSON and draws the chart using d3.js. Chartly is open-source under the MIT license. …

Prevent form spam using in-browser proof-of-work

Automated bots abuse comment forms to put advertisements on websites.┬áTraditional CAPTCHAs prevent spam by exploiting the fact that computers cannot solve a particular problem easily, and that humans that can solve them are scarce/expensive/slow (but available in the regular use case). Proof of work, by contrast, exploits the fact that …

A recursive descent parser generator in JS

Ll.js provides a simple way of parsing about anything using a recursive-descent algorithm. The grammar to be parsed is written in a friendly DSL (domain specific language) in JavaScript itself that resembles EBNF. Each parser term can be annotated with a function; when the final parse tree includes the term, …