@hot-updater/postgres 0.17.0 → 0.18.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,22 @@
1
+ import * as _hot_updater_plugin_core0 from "@hot-updater/plugin-core";
2
+ import { DatabasePluginHooks } from "@hot-updater/plugin-core";
3
+ import pg, { PoolConfig } from "pg";
4
+ import { AppVersionGetBundlesArgs, GetBundlesArgs, UpdateInfo } from "@hot-updater/core";
5
+
6
+ //#region src/postgres.d.ts
7
+ interface PostgresConfig extends PoolConfig {}
8
+ declare const postgres: (config: PostgresConfig, hooks?: DatabasePluginHooks) => (options: _hot_updater_plugin_core0.BasePluginArgs) => _hot_updater_plugin_core0.DatabasePlugin;
9
+
10
+ //#endregion
11
+ //#region src/getUpdateInfo.d.ts
12
+ declare const appVersionStrategy: (pool: pg.Pool, {
13
+ platform,
14
+ appVersion,
15
+ bundleId,
16
+ minBundleId,
17
+ channel
18
+ }: AppVersionGetBundlesArgs) => Promise<UpdateInfo | null>;
19
+ declare const getUpdateInfo: (pool: pg.Pool, args: GetBundlesArgs) => Promise<UpdateInfo | null> | null;
20
+
21
+ //#endregion
22
+ export { PostgresConfig, appVersionStrategy, getUpdateInfo, postgres };
package/dist/index.d.ts CHANGED
@@ -1,2 +1,22 @@
1
- export * from "./postgres";
2
- export * from "./getUpdateInfo";
1
+ import * as _hot_updater_plugin_core0 from "@hot-updater/plugin-core";
2
+ import { DatabasePluginHooks } from "@hot-updater/plugin-core";
3
+ import pg, { PoolConfig } from "pg";
4
+ import { AppVersionGetBundlesArgs, GetBundlesArgs, UpdateInfo } from "@hot-updater/core";
5
+
6
+ //#region src/postgres.d.ts
7
+ interface PostgresConfig extends PoolConfig {}
8
+ declare const postgres: (config: PostgresConfig, hooks?: DatabasePluginHooks) => (options: _hot_updater_plugin_core0.BasePluginArgs) => _hot_updater_plugin_core0.DatabasePlugin;
9
+
10
+ //#endregion
11
+ //#region src/getUpdateInfo.d.ts
12
+ declare const appVersionStrategy: (pool: pg.Pool, {
13
+ platform,
14
+ appVersion,
15
+ bundleId,
16
+ minBundleId,
17
+ channel
18
+ }: AppVersionGetBundlesArgs) => Promise<UpdateInfo | null>;
19
+ declare const getUpdateInfo: (pool: pg.Pool, args: GetBundlesArgs) => Promise<UpdateInfo | null> | null;
20
+
21
+ //#endregion
22
+ export { PostgresConfig, appVersionStrategy, getUpdateInfo, postgres };