Skip to content

Commit

Permalink
refactor: allow CommonJS require() without .default (#150)
Browse files Browse the repository at this point in the history
  • Loading branch information
mattbretl authored Apr 10, 2021
1 parent 8a848f5 commit 60eaf9c
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -79,4 +79,6 @@ const PostGraphileConnectionFilterPlugin: Plugin = (builder, configOptions) => {
PgConnectionArgFilterOperatorsPlugin(builder, options);
};

export default PostGraphileConnectionFilterPlugin;
// TODO: In the next major version, change `export =` to `export default`.
// This will be a breaking change for CommonJS users.
export = PostGraphileConnectionFilterPlugin;
1 change: 1 addition & 0 deletions tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
"noUnusedParameters": true,
"noUnusedLocals": true,
"preserveWatchOutput": true,
"esModuleInterop": true,
"lib": ["es2018", "esnext.asynciterable"]
},
"include": ["src/**/*"]
Expand Down

0 comments on commit 60eaf9c

Please sign in to comment.