Skip to content

Commit

Permalink
fix(interfaces): allow synthetic default imports
Browse files Browse the repository at this point in the history
Fixes Knex.Config not being typed properly after being built

Closes #14

Signed-off-by: Will Soto <willsoto@users.noreply.github.com>
  • Loading branch information
willsoto committed Feb 14, 2019
1 parent 6f532f4 commit c1074a4
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions lib/interfaces.ts
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
import { Type } from "@nestjs/common";
import { ModuleMetadata } from "@nestjs/common/interfaces";
import Knex from "knex";
import knex from "knex";
import { Model } from "objection";

export interface ObjectionModuleOptions {
Model?: typeof Model;
config: Knex.Config;
config: knex.Config;
}

export interface ObjectionModuleOptionsFactory {
Expand All @@ -26,4 +26,4 @@ export interface ObjectionModuleAsyncOptions
): Promise<ObjectionModuleOptions> | ObjectionModuleOptions;
}

export type Connection = Knex;
export type Connection = knex;
2 changes: 1 addition & 1 deletion tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
{
"compilerOptions": {
"allowSyntheticDefaultImports": true,
"baseUrl": ".",
"emitDecoratorMetadata": true,
"esModuleInterop": true,
"experimentalDecorators": true,
"lib": ["esnext"],
"module": "es2015",
Expand Down

0 comments on commit c1074a4

Please sign in to comment.