# export-files [![NPM version](https://img.shields.io/npm/v/export-files.svg)](https://www.npmjs.com/package/export-files) [![Build Status](https://img.shields.io/travis/jonschlinkert/export-files.svg)](https://travis-ci.org/jonschlinkert/export-files)

> node.js utility for exporting a directory of files as modules.

- [Install](#install)
- [Usage](#usage)
- [Changes](#changes)
- [Related projects](#related-projects)
- [Running tests](#running-tests)
- [Contributing](#contributing)
- [Author](#author)
- [License](#license)

_(TOC generated by [verb](https://github.com/verbose/verb) using [markdown-toc](https://github.com/jonschlinkert/markdown-toc))_

## Install

Install with [npm](https://www.npmjs.com/):

```sh
$ npm i export-files --save
```

## Usage

Specify the directory with files to export:

```js
module.exports = require('export-files')(__dirname);
//=> {a: [function], b: [function], c: [function]}
```

## Changes

**v0.2.0 - breaking changes**

* Non-javascript files are no longer handled. That functionality was moved to [to-exports](https://github.com/jonschlinkert/to-exports). This decision was made to keep this lib as fast as possible.
* This library no longer takes any arguments besides the directory to read.

## Related projects

You might also be interested in these projects:

* [export-dirs](https://www.npmjs.com/package/export-dirs): Export directories and their files as node.js modules. | [homepage](https://github.com/jonschlinkert/export-dirs)
* [file-reader](https://www.npmjs.com/package/file-reader): Read a glob of files, dynamically choosing the reader or requiring the files based on… [more](https://www.npmjs.com/package/file-reader) | [homepage](https://github.com/jonschlinkert/file-reader)
* [map-files](https://www.npmjs.com/package/map-files): Return an object for a glob of files. Pass a `rename` function for the keys,… [more](https://www.npmjs.com/package/map-files) | [homepage](https://github.com/jonschlinkert/map-files)
* [to-exports](https://www.npmjs.com/package/to-exports): Create exports from a directory of non-javascript or javascript files. | [homepage](https://github.com/jonschlinkert/to-exports)

## Running tests

Install dev dependencies:

```sh
$ npm i -d && npm test
```

## Contributing

Pull requests and stars are always welcome. For bugs and feature requests, [please create an issue](https://github.com/jonschlinkert/export-files/issues/new).

## Author

**Jon Schlinkert**

* [github/jonschlinkert](https://github.com/jonschlinkert)
* [twitter/jonschlinkert](http://twitter.com/jonschlinkert)

## License

Copyright © 2016 [Jon Schlinkert](https://github.com/jonschlinkert)
Released under the MIT license.

***

_This file was generated by [verb](https://github.com/verbose/verb) on January 29, 2016._