tea time with jax

1: Initialize For Rails:
gem "jax", "~> 2.0"
rails generate jax:install
Or, for Standalone Jax, install Ruby and then Jax:
gem install jax
Generate the app:
jax new demo
2: Generate Generate the controller:
jax generate controller teapots
Generate the material:
jax generate material phong
Generate the light source:
jax generate light sun directional
3: Code Edit this file:
app/controllers/assets/jax/teapots_controller.js.
Add the sun light:
@world.addLightSource "sun"
Add a teapot:
@world.addObject new Jax.Model
  position: [0, 0, -5]
  mesh: new Jax.Mesh.Teapot
    material: "phong"
4: Profit! Start the test server:
jax server
See your demo in its test environment at localhost:3000/jax! (Remove /jax for non-Rails)
Stop the test server with
Control-C
.
Package the application for production:
rake assets:precompile
Deploy and enjoy!