Prototyping an application is one thing, but making sure it's ready to launch is a whole different story. This book will enable you to create maintainable, high performance, and scalable web applications that will meet your production needs. From getting started to how to develop, hone, and protect
Mastering web application development with Express a comprehensive guide to developing production-ready web applications with Express
β Scribed by VlΔduΕ£u, Alexandru
- Publisher
- Packt Pub
- Year
- 2014
- Tongue
- English
- Leaves
- 358
- Series
- Community experience distilled
- Category
- Library
No coin nor oath required. For personal study only.
β¦ Synopsis
Cover; Copyright; Credits; About the Author; About the Reviewers; www.PacktPub.com; Table of Contents; Preface; Chapter 1: Diving into Express; The best parts of Express; Comparing Express with other frameworks; Goal; Conventions; Databases; Views; Overall; Use cases; Complex applications with heavy I/O bound operations; Single-page applications; Reusable applications; Code sharing between the server and the client; A base to create more complex frameworks; Bad use cases; Express into the wild; Application structure; Group files by features; Model-View-Controller.;If you are a Node.js developer who wants to take your Express skills to the next level and develop high performing, reliable web applications using best practices, this book is ideal for you. The only prerequisite is knowledge of Node.js.
β¦ Table of Contents
Cover
Copyright
Credits
About the Author
About the Reviewers
www.PacktPub.com
Table of Contents
Preface
Chapter 1: Diving into Express
The best parts of Express
Comparing Express with other frameworks
Goal
Conventions
Databases
Views
Overall
Use cases
Complex applications with heavy I/O bound operations
Single-page applications
Reusable applications
Code sharing between the server and the client
A base to create more complex frameworks
Bad use cases
Express into the wild
Application structure
Group files by features
Model-View-Controller. Developing a real MVC applicationSummary
Chapter 2: Component Modularity Using Middleware
Connecting middleware
The functionality of middleware
Pushing items to an array
Looking at the execution flow using logs
Creating configurable middleware
Closures to the rescue
Caching middleware --
a practical example
A first try at the caching middleware
Measuring the performance benefits of the caching middleware
Making the caching middleware configurable
Environment-based loading of middleware
Express routes
Specifying the path
Reusable route handlers
Route wildcards. Ordering of middlewareHandling errors with middleware
Mounting subapplications
Replicating the middleware system
The main file
Handling requests
Demoing the application
Adding the routes handler
Summary
Chapter 3: Creating RESTful APIs
An overview of REST
HTTP methods (verbs)
HTTP status codes
Successful 2xx
Redirection 3xx
Client error 4xx
Server error 5xx
SmartNotes application requirements
Creating the RESTful URLs of the application
Implementing the SmartNotes application
The bootstrapping phase
Dealing with validation
Creating a custom validation module. Improving performance with memoizationImplementing the models
Test helpers
The Note model
The User model
Functional tests and route implementation
User endpoints
Notes endpoints
API versioning
API rate limiting
Throttling
Facilitating caching
Content negotiation
Summary
Chapter 4: Leveraging the Power of Template Engines
The different types of template engines
Logic-less template engines
Template engines with logic
Programmatic template engines
View helpers and application-level data
Sharing code between templates with partial views
DRY templates with layouts. Template engine consolidation with consolidate.jsView caching in production
The view cache setting and its effect
Clearing the cache without a restart
Integrating a template engine with Express
Choosing a template engine
Summary
Chapter 5: Reusable Patterns for a DRY Code Base
Creating the MovieApp sample application
Application structure and required modules
Creating the server.js file
Creating the route handlers
Doing the heavy lifting inside the model
Wrapping it up
Error checks and callback functions
Tiny modules for better control flow
Ensuring a single callback execution.
π SIMILAR VOLUMES
Packt Publishing, 2014. β 358 p. β ISBN-10: 1783981083, ISBN-13: 978-1783981083.<br/>ΠΠ° Π°Π½Π³Π». ΡΠ·ΡΠΊΠ΅.<div class="bb-sep"></div>Prototyping an application is one thing, but making sure it's ready to launch is a whole different story. <strong>This book will enable you to create maintainable, high perfo
<p> Learn how to develop web applications with the Express framework from scratch</p> <p><b>Overview</b></p> <ul> <li>Exploring all aspects of web development using the Express framework</li> <li>Starts with the essentials</li> <li>Expert tips and advice covering all Express topics</li> </ul> <p><b>
<p> Learn how to develop web applications with the Express framework from scratch</p> <p><b>Overview</b></p> <ul> <li>Exploring all aspects of web development using the Express framework</li> <li>Starts with the essentials</li> <li>Expert tips and advice covering all Express topics</li> </ul> <p><b>
Express is a minimal and flexible node.js web application framework, providing a robust set of features for building single and multi-page, and hybrid web applications. It provides a thin layer of features fundamental to any web application, without obscuring features that developers know and love i
Express is a minimal and flexible node.js web application framework, providing a robust set of features for building single and multi-page, and hybrid web applications. It provides a thin layer of features fundamental to any web application, without obscuring features that developers know and love i