do you know an alternative to jrails?
It's more or less outdated (uses jQuery 1.5 - now 1.7 is the current release).
Does anybody know an alternative?
Thanks
EDIT:
I know how to build the rails helper with jquery allone - but I like the rails helpers, so I dont want to use jquery allone (without jrails)
Having always used the Prototype helpers with Rails, I recently decided to move over to using JQuery. At first I looked at JRails, since it was a drop-in replacement and hence would require minimum effort.
BUT! After reading more about JQuery and playing around with it, it became apparent to me that the best way to use Rails and JQuery together is to handle it all yourself. This might sound like a more complicated, time consuming approach but it's honestly not! I see this approach as giving you two main benefits:
.js.erb
templates rather than using RJS templates, which gives you much finer control and is easier for front-end designers who are familiar with JQuery to get to grips with (the indirection of RJS, with it's Page object, is often confusing)So, I recommend the first thing you do is watch the excellent JQuery Railscasts: http://railscasts.com/episodes/136-jquery. It's only a few minutes long and you'll be amazed at how easy and elegant it is to write AJAX code using JQuery and Rails.
You'll obviously need to get up to speed with JQuery too, but there are many excellent resources out there for this. JQuery is such an desirable skill these days, you'll be really thankful you took this approach.
Right now there's no real alternative. However, you can install jRails then upgrade the jQuery installation simply replacing the javascript files (except jrails.js) in the javascripts folder.
The only issue I'm aware of about jRails is that current version isn't compatible with Ruby 1.9.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With