| Author |
jQuery issues
|
Aaron Diffenderfer
Greenhorn
Joined: Mar 24, 2009
Posts: 12
|
|
|
What are some of the main areas that people struggle with when learning jQuery?
|
 |
Michael A Hoffman
Greenhorn
Joined: Mar 04, 2009
Posts: 19
|
|
A few things I struggled with:
1) I was leveraging Spring MVC and jQuery together and my html element IDs leveraged dot notation. For example, I would have <input id="myObj.firstName" />. jQuery, of course, needs special characters escaped as part of the selector. I can't tell you how many times I forgot to escape a dot and had an issue arise.
2) I pulled my JavaScript code out of my JSPs and put them into jQuery widgets as much as possible. This allowed me to get better integration with the IDE; however, Eclipse still does not do the justice necessary for validating jQuery expressions. Often I would fat finger jQuery expressions and have failing code. FireBug is a life saver.
3) Performance became an issue several times when I emptying and rebuilding a container. We had several HTML tables that were rebuilt through JavaScript when an add, edit or delete was performed. Initially, I attempted to build and append each table column and table row; however, I got remarkable improvements by building a string buffer and then appending the entire buffer at the end of concatenation.
|
 |
Keith Wood
Author
Ranch Hand
Joined: Aug 28, 2012
Posts: 38
|
|
|
I find that many people struggle with the asynchronous nature of JavaScript events and Ajax and the use of callback functions to be called at the appropriate time in the future.
|
Author of the upcoming "Extending jQuery" book from Manning.
|
 |
 |
|
|
subject: jQuery issues
|
|
|