We've all seen some horrible JavaScript. Name the top five things you see that lead to horrible JavaScript applications. Feel free to elaborate on each of your points.
I'll start, in no particular order:
- Poor organization in the file system
- Poor abstraction
- Seemingly endless indentation in nested callbacks / if / else if / etc.
- Poor understanding of "the bad parts" (forgot to
var
) - Poor understanding of what's fast and what's slow (querying the DOM instead of caching elements, delegating mouseover, etc)