Skip to Content
Pro Node.js for Developers
book

Pro Node.js for Developers

by Colin J. Ihrig
November 2013
Intermediate to advanced
308 pages
8h 8m
English
Apress
Content preview from Pro Node.js for Developers

CHAPTER 4

image

Events and Timers

The previous chapter introduced Node's event-driven programming model. This chapter takes a more in-depth look at events and event handling. A solid understanding of event handling will allow you to create sophisticated, event-driven applications, such as web servers. This chapter introduces event emitters—objects used to create new events. After learning how to create events, the chapter turns to event handling. Finally, the chapter wraps up with a discussion of timers and function scheduling in Node.

Event Emitters

In Node, objects that generate events are called event emitters. Creating an event emitter is as simple ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Node.js in Practice

Node.js in Practice

Marc Harter, Alex Young
Building APIs with Node.js

Building APIs with Node.js

Caio Ribeiro Pereira

Publisher Resources

ISBN: 9781430258605Purchase book