Welcome to the Treehouse Community

The Treehouse Community is a meeting place for developers, designers, and programmers of all backgrounds and skill levels to get support. Collaborate here on code errors or bugs that you need feedback on, or asking for an extra set of eyes on your latest project. Join thousands of Treehouse students and alumni in the community today. (Note: Only Treehouse students can comment or ask questions, but non-students are welcome to browse our conversations.)

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and a supportive community. Start your free trial today.

JavaScript jQuery Basics Introducing jQuery Animating Elements with jQuery

Ian Salmon
PLUS
Ian Salmon
Courses Plus Student 10,685 Points

Installing jQuery now

I know that Treasure said she would go over this in a later video, but I really wanted this information now (as I'm sure of my colleagues reading this do too).

NODE - if you have npm you can install from the CLI

npm install jquery

Other methods listed here: http://jquery.com/download/

Ian Salmon
Ian Salmon
Courses Plus Student 10,685 Points

Michael Cook absolutely! That's a great way. This was just easier for me since I had node installed.

1 Answer

Hey Ian, if you want to run jQuery locally, it's really as simple as adding it as an external file the same way you would with any other JavaScript file. First go to the jQuery website: https://jquery.com/ and download the jQuery file (I highly recommend the minified file). Then copy and paste this script tag into your code: <script text="text/javascript" src="jquery-3.3.1.min.js"></script> and you'll be ready to write jQuery for your own projects on your local drive.

Note: Make sure you specify the correct file path to the script tag based on where you save a copy of the jQuery file on your machine. Happy coding!