vesln/temporary — pull request #10 by tschaub (2013-09-06 19:06:04+00:00)
Title: Export Dir and File from index

Currently, [`index.js` requires](https://github.com/vesln/temporary/blob/9acb49baecd22a9615bc62dd969aa17c514b2bcb/index.js#L18-L26) [`file.js`](https://github.com/vesln/temporary/blob/9acb49baecd22a9615bc62dd969aa17c514b2bcb/file.js) and [`dir.js`](https://github.com/vesln/temporary/blob/9acb49baecd22a9615bc62dd969aa17c514b2bcb/file.js) which are both empty files.

This makes the following fail:
```js
var tmp = require('temporary');
var dir = new tmp.Dir(); // fails because Dir is {}
var file = new tmp.File(); // fails because File is {}
```

The readme suggests `require('temporary/lib/file')`, but this doesn't let you change your file layout while preserving the same API. Instead it seems like it would be more future-proof to export the `File` and `Dir` constructors in your `index.js` (which is listed as the `main` in `package.json`).