doc: reflect new require('events') behaviour
We don't need to do `require('events').EventEmitter` any longer. PR-URL: https://github.com/iojs/io.js/pull/975 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: Brendan Ashworth <brendan.ashworth@me.com>
This commit is contained in:
parent
85a92a37ef
commit
a28945b128
@ -20,7 +20,11 @@ attached to.
|
|||||||
|
|
||||||
## Class: events.EventEmitter
|
## Class: events.EventEmitter
|
||||||
|
|
||||||
To access the EventEmitter class, `require('events').EventEmitter`.
|
Use `require('events')` to access the EventEmitter class.
|
||||||
|
|
||||||
|
```javascript
|
||||||
|
var EventEmitter = require('events');
|
||||||
|
```
|
||||||
|
|
||||||
When an `EventEmitter` instance experiences an error, the typical action is
|
When an `EventEmitter` instance experiences an error, the typical action is
|
||||||
to emit an `'error'` event. Error events are treated as a special case in
|
to emit an `'error'` event. Error events are treated as a special case in
|
||||||
|
Loading…
x
Reference in New Issue
Block a user