background preloader

CoffeScript

Facebook Twitter

Vimperator. Kill Demo Want to create cool visuals using CoffeeScript and Processing.js? Excellent, me too. Read on. Particulars In the end, this sketch weighs in under 70 lines of CoffeeScript, and was a breeze to write. While it doesn’t do anything profound, it is pretty to look at and fun to tweak. Follow this guide and soon, you too can have some pretty in-browser javascript-canvas visuals to play with.

Here’s the Demo (reload for new patterns) and the Source Pregame I’ll be using BaseJSApp to start. Grab your friends First, we need Processing.js. We won’t be pre-compiling our CoffeeScript with node. Now, create a new CoffeeScript that we can work on. Some HTML Put three new script tags in /index.html linking to Processing.js, the CoffeeScript compiler, and the .coffee file: <! If you’re using BaseJSApp or Sinatra as the webserver for this app, you’ll need to tell sinatra/rack how to handle .coffee files.

Pulses Processing.js relies on canvas for its awesome drawing skills. <! Easy. a Quick note on Processing. Using only CoffeeScript to build an SmartPhone Application. Js2coffee: convert JavaScript code to CoffeeScript. ClojureScript vs Coffeescript « Metaphysical Developer. A language that doesn’t affect the way you think about programming, is not worth knowing – Alan J. Perlis Edit Feb/2014: Please note that this post is from 2011, a few weeks after Clojurescript was released. Things changed a lot in the mean time… In the past few years Javascript has gained a lot of attention and ubiquity: HTML5 technologies leverage a lot of Javascript, which enables people to create amazing dream worlds (like the in the ROME project) with WebGL, V8 brings a lot of JIT techniques to a JavaScript Virtual Machine which helps Google Chrome be a very fast browser, and powers NodeJS (allowing people to create a web page in a single programming language).

Javascript also powers queries in NoSQL databases like Mongo and CouchDB, and it can be used when making QT applications, 3d Games in Unity and even mobile apps with frameworks like WebMynd and PhoneGap. In spite of all of this attention, Javascript has been so misunderstood that attention to its Good Parts had to drawn. Cookbook. CoffeeScript.