Explore our extensive collection of courses designed to help you master various subjects and skills. Whether you're a beginner or an advanced learner, there's something here for everyone.
Join us for our free workshops, webinars, and other events to learn more about our programs and get started on your journey to becoming a developer.
For all the self-taught geeks out there, here is our content library with most of the learning materials we have produced throughout the years.
It makes sense to start learning by reading and watching videos about fundamentals and how things work.
Data Science and Machine Learning - 16 wks
Full-Stack Software Developer - 16w
Search from all Lessons
Curated list of small interactive and incremental exercises you can take to get better at any coding skill.
Curated section of projects to build while learning with simple instructions, videos, solutions, and more.
Guides on different topics related to the technologies that we teach in our courses
The first step to add NodeJs to our system would be to access this link and select the Operative System to start the loading.
To complete the installation on Windows, you must follow the steps described in the installer. It doesn't require any configuration while it's installing, so it will be "next", "next", "next", "finish".
To verify it has been installed correctly:
If installed correctly, it should appear a response similar to the one shown below.
The version could be different.
Once we access the download area (the link above), we must select
macOS installer and download it.
Because it doesn't require any type of modification while installing, you will only have to start the installer and follow the steps ("next", "next", "next", "finish".)
If you want to do the installation from the terminal, you can do it via, you could do it through the homebrew package manager.
To do the installation, we must execute the following command on the terminal
To install NodeJs using MacPorts as a package manager, you will have to open the terminal and type
To verify the installation, either by downloading from NodeJs, Homebrew, or MacPorts, you will have to open the terminal and run the following command
node --version. If it was installed correctly, a message similar to this will be shown:
The version could be different.
Because Linux comes in different versions, we will talk about how to install NodeJs on Ubuntu only.
Important note: Because we will be using the Super user to do the installations, you will most likely be asked for your password to complete the steps.
Every time that we are going to add new software to our system based on Linux, we must update our
local package indexes, and then we can install the package that we want, in this case,
We have to install npm (Node Package Manager) to manage the NodeJs packages because it doesn't come included in the version described.
If we want to install a different version of NodeJs to the one we can install with the previous resource, we can use a PPA (Personal Package Archive) maintained by NodeSource. In the PPA you can find more versions of the package than in the Ubuntu repository.
As we mentioned before, it is necessary to do an update and upgrade every time we want to install new packages to optimize the compatibility of the packages and use the last version of our programs and systems:
If by any chance we don't have installed cURL, we can install it this way:
Now that we are ready to add the NodeJs repository, remember to change
setup_18.x for the version that you want to install, for example,
Once you have added the repository of your choice, we must proceed to install it:
This way it is not necessary to install NPM because it already comes included in the package that we just installed.
To verify the installation of NodeJs and NPM on Linux, we will open the terminal and type
If it was installed correctly, it will be shown the following information, for NodeJs
v18.15.0 and for NPM
9.5.0. Both returns will depend on the installed version. In that way, we can use the command:
With these commands, we can know where the packages are installed.
Let's say that we have an
This is going to be the
js code that will be in our
To execute this code, we have to open the terminal or CMD (if you are using Windows), and type
node followed by where the js file that we want to execute is located.
Example: let's suppose that we have our
app.js file in the unit
If the correct address where the file is located has been passed, it will be displayed in the console:
You can learn related content and much more on the blog of 4Geeks.