fix:第一次提交,当前还有很多BUG
This commit is contained in:
Vendored
+26
@@ -0,0 +1,26 @@
|
||||
declare module 'sql.js' {
|
||||
export type QueryExecResult = {
|
||||
columns: string[]
|
||||
values: unknown[][]
|
||||
}
|
||||
|
||||
export type Statement = {
|
||||
run(values?: unknown[]): void
|
||||
free(): void
|
||||
}
|
||||
|
||||
export type Database = {
|
||||
run(sql: string): void
|
||||
exec(sql: string): QueryExecResult[]
|
||||
prepare(sql: string): Statement
|
||||
export(): Uint8Array
|
||||
}
|
||||
|
||||
export type SqlJsStatic = {
|
||||
Database: new (data?: Uint8Array | Buffer) => Database
|
||||
}
|
||||
|
||||
export default function initSqlJs(options?: {
|
||||
locateFile?: (file: string) => string
|
||||
}): Promise<SqlJsStatic>
|
||||
}
|
||||
Reference in New Issue
Block a user