Too Long; Didn't Read
If your web app relies on jQuery, it can make your JavaScript code unusable. The most obvious cause of this error is that you forgot to include jQuery before you used it. There are also more subtle causes that you’ll not see until you deploy your site to production. You can easily provide a locally-hosted fallback version of jQuery as follows: First try loading jQuery from Google's CDN. If the CDN fails load, it will almost certainly load fine from your own domain. If you have a.jQuery-rails gem, which automates this fallback process for you.