unetjs 3.2.4 → 4.0.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/README.md CHANGED
@@ -15,6 +15,12 @@ $ npm install unetjs
15
15
 
16
16
  The API documentation of the latest version of unet.js is published at [https://github.com/org-arl/unet-contrib/tree/master/unetsocket/js/docs](https://github.com/org-arl/unet-contrib/tree/master/unetsocket/js/docs)
17
17
 
18
+ ## Versions
19
+
20
+ ### unetjs v4.0.0
21
+
22
+ unetjs v4.0.0 picks up the breaking change in fjage.js v2.0.0. It enables automatic registration of subscriptions with the master container using `WANTS_MESSAGES_FOR` action. This is done everytime a fjage.js client subscribes to a topic. A change in fjåge to support a non-aggregating `WebSocketConnector` enabled this performance in fjage.js. So **unetjs v4.0.0 is only compatible with fjage.js v2.0.0 and above**.
23
+
18
24
  ## Usage
19
25
 
20
26
  ### Pre-defined Messages and Services
package/dist/cjs/unet.cjs CHANGED
@@ -1,8 +1,8 @@
1
- /* unet.js v3.2.4 2025-04-15T06:38:29.796Z */
1
+ /* unet.js v4.0.1 2025-05-14T14:03:47.464Z */
2
2
 
3
3
  'use strict';
4
4
 
5
- /* fjage.js v1.13.9 */
5
+ /* fjage.js v2.0.0 */
6
6
 
7
7
  const isBrowser =
8
8
  typeof window !== "undefined" && typeof window.document !== "undefined";
@@ -992,13 +992,10 @@ class Gateway {
992
992
 
993
993
  /** @private */
994
994
  _update_watch() {
995
- // FIXME : Turning off wantsMessagesFor in fjagejs for now as it breaks multiple browser
996
- // windows connecting to the same master container.
997
- //
998
- // let watch = Object.keys(this.subscriptions);
999
- // watch.push(this.aid.getName());
1000
- // let rq = { action: 'wantsMessagesFor', agentIDs: watch };
1001
- // this._msgTx(rq);
995
+ let watch = Object.keys(this.subscriptions);
996
+ watch.push(this.aid.getName());
997
+ let rq = { action: 'wantsMessagesFor', agentIDs: watch };
998
+ this._msgTx(rq);
1002
999
  }
1003
1000
 
1004
1001
  /**
package/dist/esm/unet.js CHANGED
@@ -1,6 +1,6 @@
1
- /* unet.js v3.2.4 2025-04-15T06:38:29.796Z */
1
+ /* unet.js v4.0.1 2025-05-14T14:03:47.463Z */
2
2
 
3
- /* fjage.js v1.13.9 */
3
+ /* fjage.js v2.0.0 */
4
4
 
5
5
  const isBrowser =
6
6
  typeof window !== "undefined" && typeof window.document !== "undefined";
@@ -990,13 +990,10 @@ class Gateway {
990
990
 
991
991
  /** @private */
992
992
  _update_watch() {
993
- // FIXME : Turning off wantsMessagesFor in fjagejs for now as it breaks multiple browser
994
- // windows connecting to the same master container.
995
- //
996
- // let watch = Object.keys(this.subscriptions);
997
- // watch.push(this.aid.getName());
998
- // let rq = { action: 'wantsMessagesFor', agentIDs: watch };
999
- // this._msgTx(rq);
993
+ let watch = Object.keys(this.subscriptions);
994
+ watch.push(this.aid.getName());
995
+ let rq = { action: 'wantsMessagesFor', agentIDs: watch };
996
+ this._msgTx(rq);
1000
997
  }
1001
998
 
1002
999
  /**
package/dist/unetjs.js CHANGED
@@ -4,7 +4,7 @@
4
4
  (global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory(global.unet = {}));
5
5
  })(this, (function (exports) { 'use strict';
6
6
 
7
- /* fjage.js v1.13.9 */
7
+ /* fjage.js v2.0.0 */
8
8
 
9
9
  const isBrowser =
10
10
  typeof window !== "undefined" && typeof window.document !== "undefined";
@@ -994,13 +994,10 @@
994
994
 
995
995
  /** @private */
996
996
  _update_watch() {
997
- // FIXME : Turning off wantsMessagesFor in fjagejs for now as it breaks multiple browser
998
- // windows connecting to the same master container.
999
- //
1000
- // let watch = Object.keys(this.subscriptions);
1001
- // watch.push(this.aid.getName());
1002
- // let rq = { action: 'wantsMessagesFor', agentIDs: watch };
1003
- // this._msgTx(rq);
997
+ let watch = Object.keys(this.subscriptions);
998
+ watch.push(this.aid.getName());
999
+ let rq = { action: 'wantsMessagesFor', agentIDs: watch };
1000
+ this._msgTx(rq);
1004
1001
  }
1005
1002
 
1006
1003
  /**