borisyankov/DefinitelyTyped — pull request #1940 by paypac (2014-03-31 04:19:09+00:00)
Title: Node/express 'pure' referenceable types

This pull request is an alternative to #1931 motivated by [the discussion there](https://github.com/borisyankov/DefinitelyTyped/pull/1931#issuecomment-39026436) about the problem of type definitions 'bleeding' into the 'member' declaration space.

This branch makes all the node/express type definitions 'pure' (ie they don't introduce any global/variable declarations). The downside is that it necessarily involves a breaking change that affects other typings that had to rely on the only method of getting types out of external module declarations as follows:
```javascript
declare module "ws" {
import events = require('events');

class WebSocket extends events.EventEmitter {
static CONNECTING: number;
static OPEN: number;
...
```
These must now be rewritten as follows:
```javascript
declare module "ws" {

class WebSocket implements NodeJs.Events.EventEmitter {
static CONNECTING: number;
static OPEN: number;
...
```