ki is a functional programming language that expands into JavaScript through a very thin layer of sweet.js macros. It is designed to complement JavaScript, enriching it with functional programming idioms and immutable data structures. ki can be used to write entire applications, individual components (e.g. state management) or just functional one-liners.
ki syntax and semantics are heavily inspired by Clojure. Thanks to mori, ki incorporates ClojureScript’s persistent data structures and related API. Here’s a taste of what ki looks like when intermixed with JavaScript:
var nums = ki (take 6 (map (fn [x] (js x * 2)) (range 1000)));
npm install -g ki
ki -o main.out.js main.js
ki has lambdas, lexical scoping, namespaces, local bindings, recursion, persistent data structures, lazyness, data literals, keywords, multiple arity functions, backcall-style continuations, multimethods, atoms and macros. And source maps.
MIT license, Copyright (C) 2014 Luca Antiga.