Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

JavaScript

Installing homebrew, npm and node - where do I find them on computer?

Hi! I am new to packages and just want to be sure on what's going here... I installed homebrew, npm and node at my mac with the terminal following this guide: https://treehouse.github.io/installation-guides/mac/node-mac.html

Is homebrew, npm and node saved just as files in finder? Or are they programs that should be among applications? For example I can't see home brew anywhere except when I used it in the terminal.

When I search for npm on my computer I find 2 files called node_modules. One in the file flashcards and one in the file Debug node Applications with VS code (both are downloaded from courses at treehouse). Is this the npm-package? Why is it at 2 places? Since I am done with these courses I want to delete those files - is that "ok"?

Bonus question: I installed Xcode because I read had to have that for installing the other stuff... and it is saved as a program. But I am not sure on when or how to use Xcode?

1 Answer

To locate homebrew, npm and node try the which command in terminal. For example I used which brew and found

kris$ which brew
/usr/local/bin/brew

which is an alias for

/usr/local/Homebrew/bin/brew

Here is the npm doc for folder use and the npm doc for install. For local installs packages are installed in the node_modules folder in the project folder. So each project will have its own local node_modules folder. You should be able to delete the project folder if no longer needed.

Files installed with Xcode are used by other applications. You don't have to learn or use Xcode yourself.