Compiling rails models directly into ajax javascript models using opal.