Ruby CoffeeScript is a bridge to the official CoffeeScript compiler.
gem install coffee-script
Note: This compiler library has replaced the original CoffeeScript compiler that was written in Ruby.
This library depends on the
coffee-script-source gem which is
updated any time a new version of CoffeeScript is released. (The
coffee-script-source gem's version number is synced with each
official CoffeeScript release.) This way you can build against
different versions of CoffeeScript by requiring the correct version of
In addition, you can use this library with unreleased versions of
CoffeeScript by setting the
json library is also required but is not explicitly stated as a
gem dependency. If you're on Ruby 1.8 you'll need to install the
json_pure gem. On Ruby 1.9,
json is included in the
coffee-script library will automatically choose the best
Node.js. If the
nodebinary is available in
$PATH, it will be used to invoke the CoffeeScript compiler.
jsc. This way you don't need to install any additional dependencies.
V8. Shelling out to Node.js may be too slow for your production environment. In this case, install
therubyracergem, which provides a fast bridge between Ruby and V8.