Skip to content

Commit

Permalink
Replace ES6 export with node export (#135)
Browse files Browse the repository at this point in the history
While ES6 loaders that are back-compatible with node modules will treat this the same, this improves the situation for uses or node and flow.

Fixes #85
  • Loading branch information
leebyron authored Jan 30, 2018
1 parent cc0c62b commit a95673c
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ export type CacheMap<K, V> = {
* different access permissions and consider creating a new instance per
* web request.
*/
export default class DataLoader<K, V> {
class DataLoader<K, V> {
constructor(
batchLoadFn: BatchLoadFn<K, V>,
options?: Options<K, V>
Expand Down Expand Up @@ -337,3 +337,5 @@ type LoaderQueue<K, V> = Array<{
resolve: (value: V) => void;
reject: (error: Error) => void;
}>;

module.exports = DataLoader;

0 comments on commit a95673c

Please sign in to comment.