Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@vlcn.io/xplat-api

Package Overview
Dependencies
Maintainers
1
Versions
51
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@vlcn.io/xplat-api - npm Package Compare versions

Comparing version 0.7.0 to 0.8.0-next.0

dist/__tests__/xplat-api.test.d.ts

31

dist/xplat-api.d.ts

@@ -23,4 +23,9 @@ export type DELETE = 9;

}
export type DBAsync = {
readonly siteid: string;
export type TMutex = {
runExclusive<T>(cb: () => Promise<T> | T): Promise<T>;
acquire(): Promise<() => void>;
release(): void;
};
export interface TXAsync {
readonly __mutex: TMutex;
execMany(sql: string[]): Promise<void>;

@@ -30,9 +35,13 @@ exec(sql: string, bind?: unknown[]): Promise<void>;

execA<T extends any[]>(sql: string, bind?: unknown[]): Promise<T[]>;
prepare(sql: string): Promise<StmtAsync>;
tx(cb: (tx: TXAsync) => Promise<void>): Promise<void>;
imperativeTx(): Promise<[() => void, TXAsync]>;
}
export interface DBAsync extends TXAsync {
readonly siteid: string;
readonly filename: string;
close(): Promise<void>;
onUpdate(cb: (type: UpdateType, dbName: string, tblName: string, rowid: bigint) => void): () => void;
prepare(sql: string): Promise<StmtAsync>;
createFunction(name: string, fn: (...args: any) => unknown, opts?: {}): void;
savepoint(cb: () => Promise<void>): Promise<void>;
transaction(cb: () => Promise<void>): Promise<void>;
};
}
export interface Stmt {

@@ -48,11 +57,11 @@ run(...bindArgs: any[]): void;

export interface StmtAsync {
run(...bindArgs: any[]): Promise<void>;
get(...bindArgs: any[]): Promise<any>;
all(...bindArgs: any[]): Promise<any[]>;
iterate<T>(...bindArgs: any[]): AsyncIterator<T>;
run(tx: TXAsync | null, ...bindArgs: any[]): Promise<void>;
get(tx: TXAsync | null, ...bindArgs: any[]): Promise<any>;
all(tx: TXAsync | null, ...bindArgs: any[]): Promise<any[]>;
iterate<T>(tx: TXAsync | null, ...bindArgs: any[]): AsyncIterator<T>;
raw(isRaw?: boolean): this;
bind(args: readonly any[]): this;
finalize(): void;
finalize(tx: TXAsync | null): Promise<void>;
}
export declare const version = 1;
//# sourceMappingURL=xplat-api.d.ts.map
{
"name": "@vlcn.io/xplat-api",
"type": "module",
"version": "0.7.0",
"version": "0.8.0-next.0",
"files": [

@@ -12,3 +12,4 @@ "dist"

"devDependencies": {
"typescript": "^4.8.4"
"typescript": "^4.8.4",
"vitest": "^0.25.2"
},

@@ -26,4 +27,5 @@ "repository": {

"watch": "tsc --build --watch",
"deep-clean": "rm -rf ./dist || true && rm tsconfig.tsbuildinfo || true"
"deep-clean": "rm -rf ./dist || true && rm tsconfig.tsbuildinfo || true",
"test": "vitest run"
}
}

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc