@planetscale/database
Advanced tools
Comparing version 1.0.1 to 1.0.2
export { format } from './sanitization.js'; | ||
export { hex } from './text.js'; | ||
declare type ReqInit = Pick<RequestInit, 'method' | 'headers'> & { | ||
body: string; | ||
}; | ||
declare type Row = Record<string, unknown>; | ||
declare type Row = Record<string, any>; | ||
interface VitessError { | ||
@@ -28,2 +25,14 @@ message: string; | ||
} | ||
declare type Req = { | ||
method: string; | ||
headers: Record<string, string>; | ||
body: string; | ||
}; | ||
declare type Res = { | ||
ok: boolean; | ||
status: number; | ||
statusText: string; | ||
json(): Promise<any>; | ||
text(): Promise<string>; | ||
}; | ||
export declare type Cast = typeof cast; | ||
@@ -35,3 +44,3 @@ export interface Config { | ||
host?: string; | ||
fetch?: (input: string, init?: ReqInit) => Promise<Pick<Response, 'ok' | 'json' | 'status' | 'statusText' | 'text'>>; | ||
fetch?: (input: string, init?: Req) => Promise<Res>; | ||
format?: (query: string, args: any) => string; | ||
@@ -67,2 +76,2 @@ cast?: Cast; | ||
export declare function connect(config: Config): Connection; | ||
export declare function cast(field: Field, value: string | null): number | string | null; | ||
export declare function cast(field: Field, value: string | null): any; |
@@ -1,1 +0,1 @@ | ||
export declare const Version = "1.0.1"; | ||
export declare const Version = "1.0.2"; |
@@ -1,1 +0,1 @@ | ||
export const Version = '1.0.1'; | ||
export const Version = '1.0.2'; |
{ | ||
"name": "@planetscale/database", | ||
"version": "1.0.1", | ||
"version": "1.0.2", | ||
"description": "A Fetch API-compatible PlanetScale database driver", | ||
@@ -5,0 +5,0 @@ "main": "dist/index.js", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
26995
333