Mastering JavaScript Design Patterns: A Practical Introduction to Building Better Applications [Video]

Mastering JavaScript Design Patterns: A Practical Introduction to Building Better Applications [Video]

Mastering
Alexandr Truhin (bumbu)

A practical introduction to writing better and more maintainable code using JavaScript design patterns
$80.75
RRP $94.99
$12.99 p/month

Get Access

Get Unlimited Access to every Packt eBook and Video course

Enjoy full and instant access to over 3000 books and videos – you’ll find everything you need to stay ahead of the curve and make sure you can always get the job done.

+ Collection
Free Sample

Video Details

ISBN 139781783980734
Course Length2 hours and 10 minutes

Video Description

As the language of the web, JavaScript is used prolifically by developers building new applications every day. However, some developers still lack the knowledge about how to write things in a simpler, clearer and more maintainable way. Design patterns are proven solutions to common development problems, and can boost code quality and application maintainability, as well as improve developer efficiency. 

Mastering JavaScript Design Patterns demonstrates how to apply design patterns in real life situations, whether that's for new, or already existing projects. It will help you to make your applications more flexible, perform better, and easier to maintain.

We’ll begin by building a simple music player application, and then we’ll build and add more and more functionality to our music player application. We’ll also cover different ways to modularize the application.

In the next two sections we’ll build a server and will load data from it. We’ll cover different techniques for caching, fallbacks, optimizing memory consumption and deferred actions.

In the last section we’ll cover code maintainability improvement techniques by using less known, yet powerful JavaScript techniques.

Style and Approach

This video course demonstrates the fundamentals of JavaScript design patterns through the practical development of an application, a music player. Each pattern will be exemplified and explained. Unlike many other guides this one is heavily practical, featuring bite sized chunks of information, detailed explanations, and real results.

Table of Contents

Introduction
The Course Overview
Software Design Patterns and Antipatterns
JavaScript Patterns Specifics
Starting the Project
Bootstrapping the Project
Adding the Play Functionality
Encapsulating Information
Abstracting Manipulation with DOM Events and Elements
Creating an Adapter to Set Intervals Using Seconds
Using Different Ways to Match Conditions
Modularizing the Application
Modularizing the Application Using Namespaces
Modularizing the Application Using AMD and Require.js
Communication Between Modules
ES6 Modules
Organizing the Application Through Separation of Concerns
Decoupling the Tracks Queue from the Tracks Player
Treating Each Track as a Separate Component
Adding the PubSub Functionality to Tracks
Enabling Track Play and Highlighting the Active Track
Decoupling the Track Model from the View
Formatting Track Time: Two-way Data Binding
Enhancing the Tracks Functionality and Adding Nested Tracks
Adding a Few Types of Tracks
Implementing Track Removal
Iterating Over Tracks Using a Generator
Iterating Over Tracks Using an Iterator
Adding Nested Tracks and Displaying Them
Fixing the Queue to Work with Nested Tracks
Building the Server and Loading Data from It
Creating the Server Using Node.js
Returning the Tracks Queue from the Server
Loading Tracks from the Server
Replacing Callbacks with Promises
Binding a Function to a Custom Context
Loading Tracks' Additional Data
Loading Tracks' Additional Data from the Server
Caching Data Loaded from the Server
Checking for Track Data with a Fallback
Storing Common Tracks Data in Shared Objects
Improving Code Maintainability
Adding Different Skins for the Player Header
Improving Testability by Inversion of Control
Forcing Function Argument Types
Fixing Models to Support Any String as Attribute Name

What You Will Learn

  • Understand how to build a practical application with the help of design patterns
  • Write robust, maintainable JavaScript applications by using battle-tested solutions to common problems
  • Improve code readability by using common solutions and better names for what you are trying to accomplish
  • Build and use a server as a data provider
  • Leverage the deferred nature of JavaScript with call-backs and promises
  • Better your communication of design goals with other programmers through usage of common terms
  • Create a separation of concerns to split modules based on different responsibilities.

Authors

Screenshots

Table of Contents

Introduction
The Course Overview
Software Design Patterns and Antipatterns
JavaScript Patterns Specifics
Starting the Project
Bootstrapping the Project
Adding the Play Functionality
Encapsulating Information
Abstracting Manipulation with DOM Events and Elements
Creating an Adapter to Set Intervals Using Seconds
Using Different Ways to Match Conditions
Modularizing the Application
Modularizing the Application Using Namespaces
Modularizing the Application Using AMD and Require.js
Communication Between Modules
ES6 Modules
Organizing the Application Through Separation of Concerns
Decoupling the Tracks Queue from the Tracks Player
Treating Each Track as a Separate Component
Adding the PubSub Functionality to Tracks
Enabling Track Play and Highlighting the Active Track
Decoupling the Track Model from the View
Formatting Track Time: Two-way Data Binding
Enhancing the Tracks Functionality and Adding Nested Tracks
Adding a Few Types of Tracks
Implementing Track Removal
Iterating Over Tracks Using a Generator
Iterating Over Tracks Using an Iterator
Adding Nested Tracks and Displaying Them
Fixing the Queue to Work with Nested Tracks
Building the Server and Loading Data from It
Creating the Server Using Node.js
Returning the Tracks Queue from the Server
Loading Tracks from the Server
Replacing Callbacks with Promises
Binding a Function to a Custom Context
Loading Tracks' Additional Data
Loading Tracks' Additional Data from the Server
Caching Data Loaded from the Server
Checking for Track Data with a Fallback
Storing Common Tracks Data in Shared Objects
Improving Code Maintainability
Adding Different Skins for the Player Header
Improving Testability by Inversion of Control
Forcing Function Argument Types
Fixing Models to Support Any String as Attribute Name

Video Details

ISBN 139781783980734
Course Length2 hours and 10 minutes
Read More