Web Development with NodeJS and MongoDB

A practical guide to building an interactive and fully-featured web application from scratch with NodeJS and MongoDB
3.8 (21 ratings)
Instead of using a simple lifetime average, Udemy calculates a
course's star rating by considering a number of different factors
such as the number of ratings, the age of ratings, and the
likelihood of fraudulent ratings.
224 students enrolled
82% off
Take This Course
  • Lectures 41
  • Length 4 hours
  • Skill Level Beginner Level
  • Languages English
  • Includes Lifetime access
    30 day money back guarantee!
    Available on iOS and Android
    Certificate of Completion
Wishlisted Wishlist

How taking a course works


Find online courses made by experts from around the world.


Take your courses with you and learn anywhere, anytime.


Learn and practice real-world skills and achieve your goals.

About This Course

Published 2/2016 English

Course Description

Web development technology moves at a very fast pace with new tools and techniques being released daily. It is impossible to learn them all, but choosing similar technologies allows you to step up your game while developing web applications. Web applications are often split into two parts: the front end and the back end. Using NodeJS for logic and MongoDB for persistence, a single person can develop a real-time web application in no time. NodeJS is based on JavaScript, which makes it easily adaptable for a wide-variety of platforms. It is also lightweight, and handles a huge number of simultaneous connections.

Web Development with NodeJS and MongoDB will show you how to build powerful web applications from the ground up. Starting with the simplest "hello world"-based script and moving on to more and more advanced techniques, this course will show you what is possible while building your application.

We'll begin with some of the basic concepts of NodeJS, ExpressJS, and MongoDB and build on this knowledge with practical examples. With each concept, the application will get more powerful and you will be able to process any business logic you may need.

We will then learn about ExpressJS to make web applications and MongoDB to persist your data. Then you will find out how to build on the shoulders of giants by consuming a RESTful API or become a giant by serving your own API. Later on, you’ll get to grips with automatically testing your application to make sure it is functioning properly.

At the end, we will take a look at deploying our application and improving its performance. The course closes with suggestions on further improvements that can be made to the application.

About The Author

Andrew Marcinkevičius is a professional web developer, and he has been building web applications for more than 5 years. He has worked with small businesses, government agencies, and start-ups to solve their problems in the field of web development.

One of his beliefs is that continuous learning should be a part of everyone's life and you learn in-depth knowledge while teaching others. He works as an independent developer and shares his thoughts on his website.

What are the requirements?

  • The course will teach you a lot about what is required to build web applications, but you should have a basic knowledge of HTML / CSS and most importantly JavaScript before starting the course.

What am I going to get from this course?

  • Write scripts in NodeJS and understand when NodeJS is the right tool for the job and when it should be avoided
  • Master the article of writing modular applications
  • Improve the quality of the application by persisting and manipulating data with MongoDB database
  • Build on the shoulders of giants by consuming your data through the RESTful API
  • Focus on the value by better understanding and quality through automatic testing
  • Improve customer retention and loyalty by ensuring your application stays fast and reliable
  • Introduce your application to the world by deploying it on the cloud

Who is the target audience?

  • If you wish to build a complete web application using JavaScript, this course is for you.

What you get with this course?

Not for you? No problem.
30 day money back guarantee.

Forever yours.
Lifetime access.

Learn on the go.
Desktop, iOS and Android.

Get rewarded.
Certificate of completion.


Section 1: Getting to Know NodeJS

This video will provide the overview of the entire course.


There are a lot of languages and frameworks that can be used for web development. This video will explain what NodeJS is, where it's used, and when you might want to use it.


It’s important to know about when and how the tool will be used. In this video, we will learn a little more about how NodeJS works.


To start making an application with NodeJS, we need to have a development environment. For this, we will install NodeJS and nodemon to help us with development.


Every programming language has its own way of executing code. You will learn how to build a sample CLI application and how to debug it.

Section 2: Understanding NodeJS Apps

To have good quality code, it's important to separate it into small pieces (modules). You will learn about CommonJS and how to make your code modular.


It's not valuable to write something that already exists and has been improved by multiple people. To start reusing the code, we will see how to use npm.


To write good applications, we need to know how the code is executed. We will see how code is executed in NodeJS.


Slow performance and high resource consumption can lower the application's quality by a great margin. Knowing how to use streams will improve the application’s performance and use fewer resources.


Working with files is a big part of making applications. You will learn how to manipulate the files using NodeJS.

Section 3: Creating MVC Apps with ExpressJS

NodeJS allows us to create what we want, but we will have to make a lot of repeating solutions ourselves to have a working web application. This can be solved by using a web framework and third-party libraries.


Applications grow fast and it can lead to spaghetti code which is hard to maintain. Adding some proved structure allows to keep applications easy to maintain, test and reuse.


To have a truly dynamic application it requires some way of distinguishing what a user is requesting. This can be done by defining routing for an application to respond to specific requests.


Creating new applications often contain the same steps. To avoid iterative tasks we can use tools and third-party libraries to scaffold our applications.


When developing dynamic applications, pages need to change depending on the data provided. Using a templating engine allows us to generate HTML pages without having to repeat ourselves.

Section 4: Persisting with MongoDB

It's very hard to make a dynamic application without storing our data for retrieval and manipulation. We will learn about the MongoDB database for persisting our data.


Different problems have different requirements for solving that problem. Knowing what NoSQL is and what it provides, allows us to choose the best tool for the job.


To have a solution which solves our problems with good performance, we need to model our data as close as possible to a real model. This can be achieved by knowing how MongoDB structures and stores data in the database.


To make the most of databases, you need to learn how to use them. We will see how to execute CRUD operations in MongoDB database.


To have the dynamic application, we need to be able to manipulate our database from our application. We will see how to connect to MongoDB and execute database operations from NodeJS.


The data we work with often contains business logic and requires things such as validation. This can be solved by representing data as objects and adding behaviors to them.

Section 5: Communicating with RESTful APIs

There can be a scenario where you need to consume data from another vendor or provide your data to a vendor. RESTful APIs provide a simple way of sharing and consuming the data.


Before providing a RESTful API for consumers, we need to know how to make one. We will see how ExpressJS helps us with that and how our API will look.


When an application is based on a different application, we need a way to consume that data. Using different ways, we will consume data from the Meetup API.


RESTful APIs start to shine when they are consumed by front-end applications. Consuming an API from the frontend allows developing the application and API separately.


CRUD is the most common operation that would be performed with our data. If our RESTful API provides them, it allows any consumer to manipulate our data.

Section 6: Unit Testing with Mocha

Fixing bugs and manual testing takes a lot of time and effort. Using unit testing and test-driven development allows us to automate testing and fix bugs early.


Manual testing is tedious and time consuming. You will learn about tools that allow us to write automated tests.


Our code should be easy to test, but it often has dependencies making it harder to test. Spying, stubbing, and faking allow us to make our code easier to test.


Our code should be easy to test, but it often has dependencies that make it harder to test. Spying, stubbing and faking allow us to make our code easier to test.


The applications are consumed on different browsers leading to different results. Using Karma we can test in multiple browsers to make sure the front-end JavaScript is working as expected.

Section 7: Shipping and Deploying

The applications are consumed on different browsers leading to different results. Using Karma we can test in multiple browsers to make sure the front-end JavaScript is working as expected.


Manually managing dependencies is time consuming. We can automate it by using a package manager.


Writing the same code again and again takes a lot of time. By publishing the package, we can simplify sharing and reusing that code.


For other people to start using our application, it has to be hosted somewhere. We will look into one of the choices for hosting—PaaS.


To make our application available for the public, it has to be hosted somewhere. Using Heroku, we can deploy it to the cloud without having to manage the infrastructure.

Section 8: Ramping Up on Full-Stack JavaScript

Slow applications can lead to lost users and revenue. Optimizing page performance enables users to continue using the application.


Applications are made from different components that often have the same logic. Making the application isomorphic allows using the same code on the server and the client.


The bigger the application grows the more complex it gets to generate its assets. Using webpack, we can automate the generation of application assets.


Some actions take a long time to finish giving an appearance of slow performance. By delegating the actions to a job queue, an application can respond faster.


There is a lot that can be done with an application. This often depends on the project requirements and resources. We will look into some ways to improve our application and improve the development workflow.

Students Who Viewed This Course Also Viewed

  • Loading
  • Loading
  • Loading

Instructor Biography

Packt Publishing, Tech Knowledge in Motion

Packt has been committed to developer learning since 2004. A lot has changed in software since then - but Packt has remained responsive to these changes, continuing to look forward at the trends and tools defining the way we work and live. And how to put them to work.

With an extensive library of content - more than 4000 books and video courses -Packt's mission is to help developers stay relevant in a rapidly changing world. From new web frameworks and programming languages, to cutting edge data analytics, and DevOps, Packt takes software professionals in every field to what's important to them now.

From skills that will help you to develop and future proof your career to immediate solutions to every day tech challenges, Packt is a go-to resource to make you a better, smarter developer.

Packt Udemy courses continue this tradition, bringing you comprehensive yet concise video courses straight from the experts.

Ready to start learning?
Take This Course