Welcome to this review of the Pluralsight course Building Web Applications with Node.js and Express 4.0 by Jonathan Mills.
Introduction and Installation
The first surprise is Jonathan says he’s going to start at the very beginning and not going to assume we know much of anything about Node.js.
So although this course is the start of the intermediate level Node JS path, it is also friendly for beginners.
Express is a web development framework for Node JS.
We see how to download Node from nodejs.org. This has changed a little and we now have a choice between LTS and current versions. However it is still supr easy to install.
Node and the Command Line
Begins with checking the Node version from the command line.
We see that we can run node from the command line and execute any commands we want. If you’ve ever used the Chrome console, or any other browser console, this should be pretty familiar.
Which Editor/IDE for Node JS Development?
As with many things in computer programming technology, advice on editors and IDEs can date quite quickly. I write this on 30th July 2016. Jonathan produced the course in late 2015 so I will point out any changes since then.
The first editor is Sublime Text, which Jonathan is a big fan of, and I also like it a lot and would probably use as my main editor if it was free.
The $70 fee is likely not very much compared with how much money you make. If it saves you a couple of hours over the duration of it’s use, then you’ll be getting good value out of it.
We see some of the features that Sublime offers. These are quite standard features for modern editors.
This is an IDE by JetBrains. Licence costs are per year and there are a variety of different licencing options available.
It’s more expensive than Sublime Text, but it is an integrated development environment and is generally more fully featured than any text editor.
Jonathan demonstrates the code completion and debugging features.
Jonathan has a lot of good things to say about Atom.
I have been using this for the past couple of months and recommend it.
Some things that I really like about Atom are:
- Very hackable – you can change anything you like to make it behave however you like
- Entirely free
- Created by the Github team and largely community driven
Brackets is a versatile IDE by Adobe.
Brackets is entirely free and is the editor Jonathan will use in this course.
Receiving an honorable mention. A very extensible editor for Node JS.
Visual Studio Code
Receiving an honorable mention. It was very new when Jonathan produced the course but is now quite a solid and mature product.
I don’t currently use Visual Studio Code as my main editor, but I recommend that you download it and see what it offers.
There are some extensions to Brackets for mod it out for proper web development.
We see the extension manager where we install our extensions.
The first extension that Jonathan recommends is the Delkos Dark Theme and you can install it using this URL. Once installed go to View->Themes to select it as your preferred theme.
Also recommended is Beautify. Use Cmd+Shift+L to beautify your code, i.e. sort out all of your indentation.
Jonathan also recommends and discusses:
- Glenn Taylor’s Brackets File Tabs extension
- Ivo Gabe de Wolff’s Brackets Icons
- Jonathan Rowny’s Brackets Snippets
Node Package Manager
We start off with Hello World and then pull in Express JS:
var express = require(‘express’);
We see an example package.json file, and we see that it’s trivial to install Express using npm and input the details into our package.json:
npm install express –save
Our package.json is updated with the version of Express with a ^ caret before it. What does this mean?
^4.xx.x – installs any version that has the same major version
~4.xx.x – installs any version that has the same minor version
4.xx.x – does not automatically install any new versions
We see demonstrations of all of these techniques in action.
Part 2 – Setting up Express is coming soon