Express.js Deep API Reference

Express.js Deep API Reference By Azat Mardan

Download

Introduction

Please read this Introduction carefully to avoid any confusion. Read it especially if you are considering buying this book to make sure it perfectly suits your level of expertise and needs. If you bought Express.js Deep API Reference already, then congratulations! As a reader of this book you are in a great position to dig deeper into the most popular web framework for the fastest growing platform. The demand for the skills in these technologies grows along with both categories of employers (startups and big corporations) adopting Node.js. The reason for that is that there’s always a gap between early adopters and mainstream ones. We are rapidly approaching the mainstream (it’s 2014-2015 during this writing). The earlier you, as a developer, jump on Node.js, the better, because if you aren’t growing, you are dying. In this Introduction, I’ll cover the following topics that will help you to get the most of the book:

Why This Book Was Written
Experss.js Deep API Reference is a derivative work from Pro Express.js. This means that this book is a more focused and concise manual for the Express.js framework. But this book has started as Express.js Guide a few years ago. The Express.js Guide (2013) was on of the first books on Express.js, which is the most popular Node.js web framework yet (as of this writing, December of 2014). That book was one of the first solely dedicated to the framework. Back in the day, Express.js’ official website (expressjs.com) had only bits of insights, and those were for advanced Node.js programmers. So no wonder that I’ve found that many people — including those who go through the HackReactor8 program and come to my Node.js classes at General Assembly and pariSOMA — were interested in a definitive manual; one that would cover how all the different components of Express.js work together in real life. The goal of The Express.js Guide was to be that resource. After the Express.js Guide became the Amazon.com #1 Best Seller in its category, Apress approached me to write this book. Express.js Deep API Reference is much more than a revision or an update of Express.js Guide. It’s a complete remake, because this book includes more things like: comments, descriptions, examples, and extras. The new book also has better-reviewed code and text, and up-to-date versions of the libraries (e.g., Express.js v4.8.1).
Many things have changed between writing the two books. Node.js was forked at io.js. TJ Holowaychuk, the creator of Express.js, stopped being actively involved with Node.js and StrongLoop maintains the framework’s repository. The development on Express.js is as rapid as ever. It’s more stable and more secure. And I see nothing but a brighter future for Express.js and Node.js!

Who Should Own This Book 
This book is intended for software engineers and web developers already fluent in programming and front-end JavaScript. To get the most of the benefits of Express.js Deep API Reference, readers must be familiar with basic Node.js concepts, like process and global, and know core modules, including stream, cluster, and buffer. If you’re thinking about starting a Node.js project or about rewriting an existing one, and your weapon of choice is Express.js — this guide is for you! It will answer most of your “how” and “why” questions.

What This Book Is
Express.js Deep API Reference is a concise book on one particular library. Unlike Practical Node.js (Apress, 2014) which covered many libraries, Express.js Deep API Reference is focused only on the single module — Express.js. Of course, in places where it’s necessary to cover other related libraries, like middleware, the book touches on those as well, but not as extensively as on the framework itself. Express.js Deep API Reference covers configuration, settings, middleware, rendering templates, request and response objects, routing, extracting params from dynamic URLs, and error handling. There are seven chapters in Express.js Deep API Reference:
1. Configuration, Settings and Environments
2. Working with Middleware
3. Template Engines and Consolidate.js
4. Parameters and Routing
5. Request
6. Response
7. Error Handling and Running an App
For more details on what the book covers, please refer to the Table of Contents.

What This Book is Not 
This book is not an introduction to Node.js, nor is it a book that covers all aspects of building a modern-day web application in great details, e.g., websockets, databases, and (of course) front-end development. Also, keep in mind that readers won’t find in Express.js Deep API Reference aids for learning programming and/or JavaScript fundamentals here, because this is not a beginners’ book. For an introduction to Node.js, MongoDB, and front-end development with Backbone.js, you might want to take a look at Azat’s book, Rapid Prototyping with JS: Agile JavaScript Development10, and the Node Program in person and online courses.
In the real world, and especially in Node.js development, due to its modularized philosophy, we seldom use just a single framework. In this book, we have tried to stick to Express.js and leave everything else out as much as possible, without compromising the usefulness of the examples. Therefore, we intentionally left out some important chunks of web development — for example, databases, authentication and testing. Although these elements are present in tutorials and examples, they’re not explained in detail. For those materials, you could take a look at the books in the Appendix A: Related Reading and Resources at the end of this book 
Share This