Initializing the project

We are going to use our computer as a development environment. Therefore, we need to have nodejs and npm installed on our computer. If you haven't done it yet, please refer to the instructions in Chapter 2, Deploying Your First Web Application.

Our first step will be to clone the helloworld GitHub repository that we created in the preceding section:

$ git clone https://github.com/<your_github_account>/helloworld.git
$ cd helloworld  

We can now create a new branch:

$ git checkout -b initial-branch  

Then, we can create an empty file called helloworld.js:

$ touch helloworld.js  

One of the best ways to write tests for these types of projects is to have a test-driven development (TDD) approach. In that process, developers first create the tests, then run them to make sure they are failing, write the code, and test again. At that point, the tests should pass. We can create a pull request and once reviewed and approved, merge it.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset