For those who have been in web development for sometime – especially those who have seen the rise (and stuck with) jQuery – then you’re likely all too familiar with some of the potential errors messages that you may see when working with the library.

But if you’re someone who is just starting out and perhaps you’re learning JavaScript and/or jQuery and you’re getting familiar with the developer tools that ship with your browser of choice, you’ve got your plate full of things that you’re having to debug.

jQuery

And sure, Google is your friend and being able to ask questions on sites such as Stack Overflow and other similar sites is nice (though the community may not always be such), but it’s not always fruitful.

In those cases, I think those of us who have gone down the same road that you’re traveling haveĀ someĀ obligation to help educate what the problem is, why it’s happening, and how to resolve it.

And that’s what I’ve tried to to do in my most recent article for Envato.

Why is jQuery Undefined?

Why is jQuery is Undefined?

In the article, I make sure that we walk through the following steps:

  1. Understanding the problem
  2. Setting up a sandbox so that we can recreate the problem
  3. Verifying that JavaScript is loaded properly
  4. Reproducing the problem
  5. Debugging the problem in various way

I also provide a downloadable resource that you can use in order to follow along with the article and in order to trace the code that’s used throughout.

No, this is not one of the fancier advanced topics that so many people like to read about, but if this is something that will help those who are coming up behind us get better at what they are doing faster than we were able to do so, then I consider it something useful and worth the time to both write and read.

Of course, if you’re beyond this point and are familiar with all of the aforementioned problems, then this article likely isn’t for you.

Comments are closed as I'd like to keep the discussion on original article.