Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Cloud/Virtualization forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Lift and jQuery

 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 64632
86
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Timothy, in this topic you linked to an informative video on Lift.

In it, you state that Lift's Ajax support leverages underlying JavaScript libraries including jQuery. Such abstraction is great, but is there any issue with using jQuery directly in on-page script to do things that are strictly client-side activities? Or does direct use of jQuery in the templates interfere with Lift's mechanics?
 
Timothy Perrett
author
Greenhorn
Posts: 19
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Bear Bibeault wrote:Timothy, in this topic you linked to an informative video on Lift.

In it, you state that Lift's Ajax support leverages underlying JavaScript libraries including jQuery. Such abstraction is great, but is there any issue with using jQuery directly in on-page script to do things that are strictly client-side activities? Or does direct use of jQuery in the templates interfere with Lift's mechanics?


Not at all actually. Its essentially a "take it or leave it" abstraction. It's primary goal is to abstract away parts of Lift plumbing so people can use different libraries without interference from some internally mandated JS lib (resulting in clashing operators etc)... meaning that if you use YUI, Lift will use YUI automatically for its Comet and AJAX actions. You can happily write all the JS code you want in regular JQuery, CoffeeScript or whatever and that won't be affected by Lift at all. You can even have Lift dynamically call your own JS code if you want as well.

Hope that helps

Tim
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 64632
86
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
It does.

Nothing aggravates me more than frameworks in which you must "do it our way or the highway". It sounds like Lift's focus and attitude is well in line with what I prefer: "we're here to help when you need it, but otherwise we stay out of your way".
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic