Oreilly - Mastering JavaScript
by Ben Fhala | Publisher: Packt Publishing | Release Date: August 2015 | ISBN: 9781784391348
Elevate your web development skills by deep diving into the power of clean, concise object oriented JavaScript, patterns, and more About This VideoMaster JavaScript best practices for designing and developing fully functional, cross-platform librariesUse powerful design patterns for an innovative and cutting-edge approach to web developmentEnhance the performance of your libraries by focusing on a new aspect in every videoIn DetailJavaScript is the browser language that supports object-oriented, imperative, and functional programming styles, focusing on website behavior. It has a rich set of libraries and frameworks and is the most widely used client-side language with features such as asynchronous communication, controlling browsers, and editing documents. JavaScript provides web developers out there with the knowledge to program more intelligently and idiomatically—something not all programmers can do or understand.Mastering JavaScript will immerse you in the JavaScript world, where you will mature as a developer by exploring the best practices for building an original, functional, and useful cross-platform library.Starting off with just some basic knowledge of JavaScript and HTML, we will first lay a solid naming foundation for OOP coding by exploring the best naming conventions practices for primitive variables, constructors, methods, and properties. Then we'll shed some light on creating global namespace, create a pure JavaScript onload script, and walk through cross-browser compatibility. We will learn how the onload and DOMContentLoaded events are actually triggered and understand how to use querySelectorAll method and dynamically load scripts using a script loader.As the course progresses, we will start building up our own libraries by integrating codes, methods, and logic, we will also expand our library with design patterns such as module, façade, adapter, and singleton. Finally, we will create a working time manager and explore unit testing in JavaScript.After working through this video course, you will be equipped with all the knowledge, tips, and hacks you need to stand out in the advanced world of web development.
- Chapter 1 : Idiomatic JavaScript
- The Course Overview 00:02:58
- Using White Space for Readability 00:05:20
- Declaring Variables 00:07:52
- Declaring Complex Data Types and Functions 00:04:22
- OOP Naming Conventions 00:04:14
- Creating a Global Namespace 00:04:46
- Constants (and Pseudo constants) 00:03:49
- Smart Coercion of Data Fields 00:04:23
- Chapter 2 : Cross-browser Development
- Targeting at JavaScript Versions or Features 00:04:53
- Creating an onload Method That Always Works 00:03:39
- OnReady – Our First Cross-browser Script 00:06:51
- Using Modernizr to Detect Features 00:04:23
- Chapter 3 : Cross-browser DOM Manipulation
- Building a Conditional Logic Flow 00:04:51
- Selecting DOM Elements Natively in HTML5 00:06:25
- Creating a Cross-browser Script Loader 00:05:37
- Using Sizzle to Select DOM Elements 00:07:14
- Chpater 4 : Creating a JavaScript Library
- Defining a Namespace 00:05:43
- Creating Private Variables in JavaScript 00:05:45
- The JavaScript Module Design Pattern 00:06:30
- Version Controlling Our Library 00:07:08
- Building Out Our Library 00:11:26
- Chapter 5 : Expanding Out with Design Patterns
- Thinking with Interfaces 00:07:21
- Creating an Adapter Design Pattern 00:05:30
- Building a jQuery Adapter 00:06:41
- Adding a Functionality Method 00:03:47
- Mimicking the jQuery Wrapper 00:09:07
- Chapter 6 : Exploring the Facade Design Pattern
- Introducing the Facade Design Pattern 00:03:56
- Creating a Facade Creator 00:04:34
- Creating a New Global Function Through the Facade 00:04:00
- Creating an Advanced Facade Pattern 00:05:19
- Chapter 7 : Working with Time in JavaScript
- Creating a Singleton 00:11:33
- Building the Constructor for Our Ticker 00:10:37
- Connecting Time with Our Ticker 00:11:10
- Processing Interval groups 00:09:46
- Exposing Our Ticker to the World 00:02:46
- Chapter 8 : Dispatching Events in JavaScript
- Creating an Event Dispatcher 00:13:35
- Integrating the Event Dispatcher into Our Library 00:08:12
- Removing Events from the Dispatcher 00:05:21
- Building Test Units 00:08:48