Book Image

Web Development with MongoDB and NodeJS Second edition

Book Image

Web Development with MongoDB and NodeJS Second edition

Overview of this book

Table of Contents (19 chapters)
Web Development with MongoDB and NodeJS Second Edition
Credits
About the Authors
About the Reviewers
www.PacktPub.com
Preface
12
Popular Node.js Web Frameworks
Index

Koa


Koa is a new web framework designed by the same team that created Express.js. The goal of Koa is to be smaller, more expressive, and a more robust foundation for web applications. T J Holowaychuk, who is the creator of the Express framework, is the same person who created Koa as well and you can see it focuses much of its capabilities on generators, which is a feature found in other popular programming languages such as Python, C#, and Ruby. Generators were introduced to JavaScript with ECMAScript 6. Generators prevent the standard callback hell that is so popular with the development process in Node.js. Koa has a lightweight architecture, so it doesn't come with any middleware, rather, it leaves the choice of implementing certain features to the developers.

The Koa website, http://koajs.com, is shown in the following screenshot:

More information about Koa and sample implementations can be found on its website as well as at https://github.com/koajs/koa.