@gudhub/core 1.2.4-beta.45 → 1.2.4-beta.47

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.
Files changed (39) hide show
  1. package/.parcel-cache/83e7562660f7cc15-BundleGraph +0 -0
  2. package/.parcel-cache/d3a1b9507cb44047-AssetGraph +0 -0
  3. package/.parcel-cache/data.mdb +0 -0
  4. package/.parcel-cache/dc1da35000e13623-RequestGraph +0 -0
  5. package/.parcel-cache/lock.mdb +0 -0
  6. package/.parcel-cache/snapshot-dc1da35000e13623.txt +160 -163
  7. package/GUDHUB/AppProcessor/AppProcessor.js +6 -20
  8. package/GUDHUB/ChunksManager/ChunksManager.test.js +3 -0
  9. package/GUDHUB/DataService/AppDataService.js +1 -200
  10. package/GUDHUB/DataService/ChunkDataService.js +0 -4
  11. package/GUDHUB/DataService/IndexedDB/IndexedDBAppService.js +224 -263
  12. package/GUDHUB/DataService/IndexedDB/IndexedDBChunkService.js +3 -227
  13. package/GUDHUB/DataService/IndexedDB/IndexedDBService.js +124 -302
  14. package/GUDHUB/DataService/IndexedDB/StoreManager/BaseStoreManager.js +9 -36
  15. package/GUDHUB/DataService/IndexedDB/StoreManager/managers.js +4 -40
  16. package/GUDHUB/DataService/IndexedDB/appRequestWorker.js +23 -88
  17. package/GUDHUB/DataService/IndexedDB/consts.js +1 -3
  18. package/GUDHUB/DataService/IndexedDB/init.js +1 -1
  19. package/GUDHUB/DataService/IndexedDB/storeManagerConf/init.js +1 -1
  20. package/GUDHUB/DataService/export.js +73 -13
  21. package/GUDHUB/DataService/httpService/AppHttpService.js +5 -15
  22. package/GUDHUB/DataService/httpService/ChunkHttpService.js +35 -37
  23. package/GUDHUB/DataService/utils.js +24 -127
  24. package/GUDHUB/GHConstructor/createAngularModuleInstance.js +7 -4
  25. package/GUDHUB/GHConstructor/createClassInstance.js +8 -3
  26. package/GUDHUB/ItemProcessor/ItemProcessor.js +0 -18
  27. package/GUDHUB/Utils/Utils.js +0 -14
  28. package/GUDHUB/WebSocket/WebSocket.js +2 -2
  29. package/GUDHUB/api/AppApi.js +13 -13
  30. package/GUDHUB/api/ChunkApi.js +5 -5
  31. package/GUDHUB/config.js +11 -2
  32. package/GUDHUB/consts.js +6 -12
  33. package/GUDHUB/gudhub.js +7 -30
  34. package/GUDHUB/gudhubAppRequestWorker.js +1 -2
  35. package/dist/gudhub.es.js +8 -1
  36. package/dist/gudhub.umd.js +2 -2
  37. package/package.json +4 -2
  38. package/GUDHUB/ChunksManager/ChunksManager.js +0 -68
  39. package/indextest.html +0 -35
package/package.json CHANGED
@@ -1,11 +1,14 @@
1
1
  {
2
2
  "name": "@gudhub/core",
3
- "version": "1.2.4-beta.45",
3
+ "version": "1.2.4-beta.47",
4
4
  "scripts": {
5
5
  "test": "NODE_ENV=test mocha $(find ./GUDHUB -print | grep -i test.js)",
6
6
  "prepublishOnly": "chmod +x ./build.sh; ./build.sh",
7
7
  "publishPublicly": "npm publish --access public"
8
8
  },
9
+ "engines": {
10
+ "node": "16.13.1"
11
+ },
9
12
  "appRequestWorker": "dist/PARCEL_APP_REQUEST_WORKER_FILENAME.js",
10
13
  "main": "./dist/gudhub.umd.js",
11
14
  "module": "./dist/gudhub.es.js",
@@ -64,7 +67,6 @@
64
67
  "mocha": "^8.1.2",
65
68
  "parcel": "2.13.3",
66
69
  "parcel-resolver-ignore": "2.2.0",
67
- "process": "^0.11.10",
68
70
  "should": "^13.2.3",
69
71
  "sinon": "^14.0.0",
70
72
  "vite": "6.0.11"
@@ -1,68 +0,0 @@
1
- // import { ChunkAPI } from "../api/ChunkApi.js";
2
-
3
-
4
- // export class ChunksManager {
5
- // constructor(
6
- // storage,
7
- // pipeService,
8
- // req,
9
- // util,
10
- // dataService,
11
- // ) {
12
- // this.storage = storage;
13
- // this.pipeService = pipeService;
14
- // this.req = req;
15
- // this.util = util;
16
- // this.dataService = dataService;
17
- // this.chunkApi = new ChunkAPI(req);
18
- // this.itemListeners();
19
- // }
20
-
21
- // async getChunk(app_id, chunk_id) {
22
- // try {
23
- // return this.dataService.getChunk(app_id, chunk_id);
24
- // } catch (err) {
25
- // console.log(err);
26
- // return null;
27
- // }
28
- // }
29
-
30
- // async getLastChunk(app_id) {
31
- // try {
32
- // return this.chunkApi.getLastChunk(app_id);
33
- // } catch (err) {
34
- // console.log(err);
35
- // return null;
36
- // }
37
- // }
38
-
39
- // async getChunks(app_id, chunk_ids) {
40
- // let chunks = [];
41
- // if(chunk_ids){
42
- // chunks = await Promise.all(chunk_ids.map((chunk_id) => this.getChunk(app_id, chunk_id)));
43
- // }
44
- // return chunks;
45
- // }
46
-
47
- // itemListeners() {
48
- // }
49
-
50
- // async getApp(app_id) {
51
- // if (!app_id) return null;
52
- // let app = this.getAppFromStorage(app_id);
53
- // if (!app) {
54
- // if (this.getAppPromises[app_id]) {
55
- // return this.getAppPromises[app_id];
56
- // }
57
- // this.getAppPromises[app_id] = this.getAppApi(app_id);
58
- // app = await this.getAppPromises[app_id];
59
- // if (app) {
60
- // this.saveAppInStorage(app);
61
- // this.ws.addSubscription(app_id);
62
- // } else {
63
- // return null;
64
- // }
65
- // }
66
- // return app;
67
- // }
68
- // }
package/indextest.html DELETED
@@ -1,35 +0,0 @@
1
- <!DOCTYPE html>
2
- <html>
3
- <body>
4
-
5
- <h1>My First Heading</h1>
6
-
7
- <p>My first paragraph.</p>
8
-
9
- <script type="text/javascript" charset="utf-8" src="file:///home/vitaly/Documents/work/gudhubclient/override_npm/gudhub/dist/gudhub.umd.js"></script>
10
-
11
-
12
- <script>
13
- const auth_key = "6be1AB+4e0iIkuyIXkpeSGbzMVTUkKaBv4Jb8u4w58LFPF5/kzOIfrojilDKbfWhyP+Rb8ik/cCXhd+2/5kigQ==";
14
- const app_id = 35902;
15
-
16
- const gudhub = new GudHub(auth_key);
17
-
18
- // const button = document.querySelector('.button');
19
- // const output = document.querySelector('h1');
20
-
21
- // button.addEventListener('click', async () => {
22
- // const app = await gudhub.getApp(app_id);
23
- gudhub.getApp(app_id).then((app) => {
24
- console.log(app);
25
- const beautifiedApp = JSON.stringify(app.app_name, null, 2);
26
- })
27
-
28
-
29
- // output.innerHTML = beautifiedApp;
30
- // });
31
- </script>
32
-
33
- </body>
34
- </html>
35
-