Give up RJS and go pure
RJS seems like a nice idea. Its Ruby with embedded Javascript.
Now put away the crayons and get back to pure Javascript with embedded Ruby with “MinusR” - RJS minus the R (for Ruby).
This is especially useful if you want a clean way to support non-Prototype/Scriptaculous frameworks, like jQuery. You can call the raw Javascript for these libraries, and embed your Ruby objects using Erb and a handy js helper to convert Ruby to JSON.
Its clean, healthy fun. Like carrots.
Makes me think about jogging, its just that healthy for you.
Trackbacks
Use this link to trackback from your own site.






I’m in.
Most of the time rjs just confuses me. This has my vote. Much directer/clearer.
Yeah, I just found RJS was a 3rd programming language of sorts. I knew Ruby, I knew Javascript, and now I needed to know RJS. If you’ve got to look up the Prototype/Scriptaculous libraries anyway to know what you can do and want classes/methods to call, may as well express it in JS.
I might change my mind in time, but I think I’ll use MinusR for awhile.
Is it possible to give an example?
Sorry, never mind, found it on Dan’s site.
[...] (Found via Dr. Nic Williams) [...]
I very much agree. Hmmm should AjaxScaffold move to use MinusR instead or would that just be a maintenance nightmare?
@richard - pragmatically - if its already working now, I don’t see significant benefits. Plus, for AjaxScaffold - a generator - there aren’t enough unit tests (last time I looked) to let you refactor with confidence.