-
Notifications
You must be signed in to change notification settings - Fork 0
Getting started
- Download the correct and most recent Git installer:
Git installer for Windows | Git installer for macOS - Start the installer. The 'Git Setup' window will pop up.
- Complete the installation by following the prompts ('Next' and 'Finish'). The default options are pretty sensible for most users.
- Open Windows PowerShell or macOS Terminal (or Git Bash, if during installation you selected not to use Git from the default CLI), use it to run the following command.
- Verify the installation by typing
git --version
. The version number will be printed, for examplegit version 2.17.1
.
- Open the terminal, use it to run the following commands.
- For users of Ubuntu / Debian / Linux Mint / elementary OS:
First, update your system's package list by typingsudo apt-get update -y
Second, install Git by typingsudo apt-get install -y git
For users of Fedora / openSUSE / CentOS / RHEL:
First, update your system's package list by typingsudo yum -y update
Second, install Git by typingsudo yum -y install git
- Verify the installation by typing
git --version
. The version number will be printed, for examplegit version 2.17.1
.
- Set a Git username by typing
git config --global user.name "Bruce Wayne"
- Set your email address by typing
git config --global user.email "[email protected]"
*Use your true details, of course. These details will be associated with any commit you create.
- Download the relevant and most recent Node.js installer directly from Nodejs.org - Downloads page.
- Start the installer. The 'Node.js Setup' window will pop up.
- Complete the installation by following the prompts ('Next' and 'Finish'). The default options are pretty sensible for most users.
*** Notes ***
(A) The installer automatically modifies thePath
variable in Windows, so that you can run npm commands from PowerShell (or CMD, if you will).
(B) npm is bundled with Node.js. - Open Windows PowerShell or macOS Terminal, use it to run the following command.
- Verify the installation by typing
node -v
. The version number will be printed, for examplev8.9.4
.
- Open the terminal, use it to run the following commands.
- For users of Ubuntu / Debian / Linux Mint / elementary OS:
First, add the Node.js repository by typingcurl -sL https://deb.nodesource.com/setup_8.x | sudo -E bash -
Second, install Node.js by typingsudo apt-get install -y nodejs
For users of Fedora / openSUSE / CentOS / RHEL:
First, add the Node.js repository by typingcurl --silent --location https://rpm.nodesource.com/setup_8.x | sudo bash -
Second, install Node.js by typingsudo yum -y install nodejs
*** Notes ***
(A) Change the version number accordingly:setup_9.x
for Node.js 9,setup_10.x
for Node.js 10, etc.
(B) The repository above is built and hosted by NodeSource. Support can be found on GitHub at nodesource/distributions.
(C) npm is bundled with Node.js. - Verify the installation by typing
node -v
. The version number will be printed, for examplev8.9.4
.
- On GitHub, navigate to the main page of the repository/project.
- Under the repository description, click Clone or download.
- Copy the URL of the repository.
- Open the CLI (or Git Bash, if you will), use it to run the following commands.
- Go into the parent directory (the location where you want to place the repository) by typing the path to that directory, for example
cd c:\path\to\parent-of-projects
- From within the parent directory, initiate the cloning process by typing
git clone
and pasting the URL you copied in Step 2, for examplegit clone https://github.com/USERNAME/REPOSITORY-NAME
. A local repository will be created (as a clone of the original repo) in the parent directory. - Go into the local repository (a.k.a. project directory) by typing the path to that directory, for example
cd c:\path\to\project-name
- From within the local repository (a.k.a. project directory), type
npm install
. The dependencies will be installed in the local 'node_modules' directory (which is located in your project directory).
*Keep the local repository synchronized with the original repository by typing the relevant Git commands, such as git pull
*View a list of dependencies by typing npm list -depth 0
- Open the CLI, use it to run the following commands.
- Go into the relevant directory (the location where you want to place the package directory) by typing the path to that directory, for example
cd c:\path\to\parent-of-projects\project-name
- For npm users:
From within the directory, typenpm install <package-name>
For Yarn users:
From within the directory, typeyarn add <package-name>
The package will be installed along with its dependencies, which results in this kind of path:c:\path\to\parent-of-projects\project-name\node_modules\package-name
.
*By default, packages are dropped into the 'node_modules' directory.
*Use this installation only for enhancing an existing project. If you intend to use the components as a standalone project, you should use another method of installation.
Place the following code within <head>
element of your HTML document.
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/packagename/1.0.3/filename.min.js">
Place the following script at the bottom of the <body>
element of your HTML document.
<script src="https://cdnjs.cloudflare.com/ajax/libs/packagename/1.0.3/filename.min.css"></script>
- Download the source code.
- Extract the project directory from the downloaded bundle (usually .zip or .tar), place it in your preferred location.
- Go into your project directory by typing
cd c:\path\to\project-name
- Type
npm install
. The dependencies will be installed in the local 'node_modules' directory (which is located in your project directory).
*This bundle includes (or may include) inline comments, prologue comments, documentation, reports, build tools, test tools, documents (.md, .txt, .pdf, .odt), vendor libraries, optional dependencies. Use it to make your own ready-to-use edition.
This bundle does NOT include inline comments, prologue comments, documentation, reports, build tools, test tools, documents (.md, .txt, .pdf, .odt), vendor libraries, optional dependencies. Also, many files are (or may be) minified. Place the files in the relevant directory, and use it as is.
Download the compiled code.