@hot-updater/standalone 0.17.0 → 0.18.1
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.
- package/dist/index.cjs +1485 -3407
- package/dist/index.d.cts +35 -0
- package/dist/index.d.ts +35 -2
- package/dist/index.js +1482 -3374
- package/package.json +4 -4
- package/dist/standaloneRepository.d.ts +0 -16
- package/dist/standaloneRepository.spec.d.ts +0 -1
- package/dist/standaloneStorage.d.ts +0 -12
package/dist/index.d.cts
ADDED
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import * as _hot_updater_plugin_core0 from "@hot-updater/plugin-core";
|
|
2
|
+
import { BasePluginArgs, DatabasePluginHooks, StoragePlugin, StoragePluginHooks } from "@hot-updater/plugin-core";
|
|
3
|
+
|
|
4
|
+
//#region src/standaloneRepository.d.ts
|
|
5
|
+
interface RouteConfig {
|
|
6
|
+
path: string;
|
|
7
|
+
headers?: Record<string, string>;
|
|
8
|
+
}
|
|
9
|
+
interface Routes {
|
|
10
|
+
upsert: () => RouteConfig;
|
|
11
|
+
list: () => RouteConfig;
|
|
12
|
+
retrieve: (bundleId: string) => RouteConfig;
|
|
13
|
+
}
|
|
14
|
+
interface StandaloneRepositoryConfig {
|
|
15
|
+
baseUrl: string;
|
|
16
|
+
commonHeaders?: Record<string, string>;
|
|
17
|
+
routes?: Routes;
|
|
18
|
+
}
|
|
19
|
+
declare const standaloneRepository: (config: StandaloneRepositoryConfig, hooks?: DatabasePluginHooks) => (options: _hot_updater_plugin_core0.BasePluginArgs) => _hot_updater_plugin_core0.DatabasePlugin;
|
|
20
|
+
|
|
21
|
+
//#endregion
|
|
22
|
+
//#region src/standaloneStorage.d.ts
|
|
23
|
+
interface StorageRoutes {
|
|
24
|
+
uploadBundle: (bundleId: string, bundlePath: string) => RouteConfig;
|
|
25
|
+
deleteBundle: (bundleId: string) => RouteConfig;
|
|
26
|
+
}
|
|
27
|
+
interface StandaloneStorageConfig {
|
|
28
|
+
baseUrl: string;
|
|
29
|
+
commonHeaders?: Record<string, string>;
|
|
30
|
+
routes?: StorageRoutes;
|
|
31
|
+
}
|
|
32
|
+
declare const standaloneStorage: (config: StandaloneStorageConfig, hooks?: StoragePluginHooks) => (_: BasePluginArgs) => StoragePlugin;
|
|
33
|
+
|
|
34
|
+
//#endregion
|
|
35
|
+
export { RouteConfig, Routes, StandaloneRepositoryConfig, StandaloneStorageConfig, StorageRoutes, standaloneRepository, standaloneStorage };
|
package/dist/index.d.ts
CHANGED
|
@@ -1,2 +1,35 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
import * as _hot_updater_plugin_core0 from "@hot-updater/plugin-core";
|
|
2
|
+
import { BasePluginArgs, DatabasePluginHooks, StoragePlugin, StoragePluginHooks } from "@hot-updater/plugin-core";
|
|
3
|
+
|
|
4
|
+
//#region src/standaloneRepository.d.ts
|
|
5
|
+
interface RouteConfig {
|
|
6
|
+
path: string;
|
|
7
|
+
headers?: Record<string, string>;
|
|
8
|
+
}
|
|
9
|
+
interface Routes {
|
|
10
|
+
upsert: () => RouteConfig;
|
|
11
|
+
list: () => RouteConfig;
|
|
12
|
+
retrieve: (bundleId: string) => RouteConfig;
|
|
13
|
+
}
|
|
14
|
+
interface StandaloneRepositoryConfig {
|
|
15
|
+
baseUrl: string;
|
|
16
|
+
commonHeaders?: Record<string, string>;
|
|
17
|
+
routes?: Routes;
|
|
18
|
+
}
|
|
19
|
+
declare const standaloneRepository: (config: StandaloneRepositoryConfig, hooks?: DatabasePluginHooks) => (options: _hot_updater_plugin_core0.BasePluginArgs) => _hot_updater_plugin_core0.DatabasePlugin;
|
|
20
|
+
|
|
21
|
+
//#endregion
|
|
22
|
+
//#region src/standaloneStorage.d.ts
|
|
23
|
+
interface StorageRoutes {
|
|
24
|
+
uploadBundle: (bundleId: string, bundlePath: string) => RouteConfig;
|
|
25
|
+
deleteBundle: (bundleId: string) => RouteConfig;
|
|
26
|
+
}
|
|
27
|
+
interface StandaloneStorageConfig {
|
|
28
|
+
baseUrl: string;
|
|
29
|
+
commonHeaders?: Record<string, string>;
|
|
30
|
+
routes?: StorageRoutes;
|
|
31
|
+
}
|
|
32
|
+
declare const standaloneStorage: (config: StandaloneStorageConfig, hooks?: StoragePluginHooks) => (_: BasePluginArgs) => StoragePlugin;
|
|
33
|
+
|
|
34
|
+
//#endregion
|
|
35
|
+
export { RouteConfig, Routes, StandaloneRepositoryConfig, StandaloneStorageConfig, StorageRoutes, standaloneRepository, standaloneStorage };
|