-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.d.ts
41 lines (36 loc) · 842 Bytes
/
index.d.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
import { Knex as KnexJS } from "knex"
export declare type Knex = KnexJS
type DatabaseGetter = {
getConnectionInfo: (
database?: string,
user?: string
) => {
host: string
user: string
port: number
password: string
database: string
ssl: boolean
}
getConnectionString: (database?: string, user?: string) => string
(params?: {
seed?: boolean
migrate?: boolean
testMode?: boolean
user?: string
}): Promise<Knex>
}
type GetDatabaseGetter = {
default: DatabaseGetter
(params?: {
migrationFile?: string
seedFile?: string
migrationSQL?: string
seedSQL?: string
pool?: { min: number; max: number }
defaults?: any
}): DatabaseGetter
}
export declare const getDatabaseGetter: GetDatabaseGetter
export declare const knex: Knex
export default getDatabaseGetter