jQuery plugin says "jQuery is not defined"
See original GitHub issueI have run the following command line arguments:
npm install --save jquery
npm install --save jquery-slimscroll
Inside of my index.js file, the first three lines import these modules:
import $ from 'jquery';
window.jQuery = $;
import 'jquery-slimscroll';
But I receive the following error:
jquery.slimscroll.js:474 Uncaught ReferenceError: jQuery is not defined
Any suggestions?
Issue Analytics
- State:
- Created 7 years ago
- Comments:7 (4 by maintainers)
Top Results From Across the Web
5 Easy Ways to Fix the "jQuery is Not Defined" Error - Kinsta
Method 2: Make Sure jQuery Is Loaded ... You may experience the “jQuery is not defined error” when jQuery is included but not...
Read more >How to fix the "jQuery is not defined" error in WordPress
The problem is usually caused by a mistake in the code. In order to fix it, use the keyboard Ctrl + U to...
Read more >javascript - JQuery - $ is not defined - Stack Overflow
That error means that jQuery has not yet loaded on the page. Using $(document).ready(.
Read more >jQuery is not defined: Common causes and a simple solution
What are the common causes of jQuery is not defined? ... The most obvious cause of this error is that you forgot to...
Read more >Fixing the Common jQuery Error in WordPress
Common Causes of getting “Uncaught ReferenceError: jQuery Is Not Defined” in WordPress · One of your plugins is conflicting with other plugins, ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
require('jquery-slimscroll');
instead of
import 'jquery-slimscroll';