aotrautils 0.0.237 → 0.0.240

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.
@@ -1,6 +1,6 @@
1
1
 
2
2
 
3
- /*utils COMMONS library associated with aotra version : «1_29072022-2359 (30/07/2022-14:17:09)»*/
3
+ /*utils COMMONS library associated with aotra version : «1_29072022-2359 (02/08/2022-02:24:51)»*/
4
4
  /*-----------------------------------------------------------------------------*/
5
5
 
6
6
 
@@ -4827,7 +4827,7 @@ AOTRAUTILS_LIB_IS_LOADED=true;
4827
4827
 
4828
4828
 
4829
4829
 
4830
- /*utils CLIENT library associated with aotra version : «1_29072022-2359 (30/07/2022-14:17:09)»*/
4830
+ /*utils CLIENT library associated with aotra version : «1_29072022-2359 (02/08/2022-02:24:51)»*/
4831
4831
  /*-----------------------------------------------------------------------------*/
4832
4832
  /* ## Utility global methods in a browser (htmljs) client environment.
4833
4833
  *
@@ -11676,7 +11676,7 @@ createFusrodaClient=function(doOnClientReady, doOnDataReception, urlParam=null,
11676
11676
 
11677
11677
 
11678
11678
 
11679
- /*utils GEOMETRY library associated with aotra version : «1_29072022-2359 (30/07/2022-14:17:09)»*/
11679
+ /*utils GEOMETRY library associated with aotra version : «1_29072022-2359 (02/08/2022-02:24:51)»*/
11680
11680
  /*-----------------------------------------------------------------------------*/
11681
11681
 
11682
11682
 
@@ -12881,7 +12881,7 @@ function rayVsUnitSphereClosestPoint(p, r) {
12881
12881
  // MUST REMAIN AT THE END OF THIS LIBRARY FILE !
12882
12882
 
12883
12883
  AOTRAUTILS_GEOMETRY_LIB_IS_LOADED=true;
12884
- /*utils SERVER library associated with aotra version : «1_29072022-2359 (30/07/2022-14:17:09)»*/
12884
+ /*utils SERVER library associated with aotra version : «1_29072022-2359 (02/08/2022-02:24:51)»*/
12885
12885
  /*-----------------------------------------------------------------------------*/
12886
12886
 
12887
12887
 
@@ -13216,6 +13216,9 @@ WebsocketImplementation={
13216
13216
  // OLD SYNTAX : serverSocket=Socket.listen(listenableServer);
13217
13217
  serverSocket=new Socket.Server(listenableServer);
13218
13218
 
13219
+ // TRACE :
13220
+ lognow("WARN : CAUTION ! ON TODAY (01/08/2022) socket.io SERVER LIBRARY IS BOGUS AND WON'T WORK (node clients can't connect !!) IF listenableServer IS A https SERVER !!!");
13221
+ lognow("listenableServer:",listenableServer);
13219
13222
 
13220
13223
  // Setting up the disctonnect event :
13221
13224
  serverSocket.on("endConnection",()=>{
@@ -13536,22 +13539,17 @@ WebsocketImplementation={
13536
13539
  return null;
13537
13540
  }
13538
13541
 
13539
-
13540
13542
  clientSocket=new WebSocket(serverURL+":"+port,/*WORKAROUND:*/{ rejectUnauthorized:false, secure: isSecure });
13541
13543
  }else{
13542
13544
  // NOW : socket.io :
13543
13545
  //client on server-side:
13544
13546
 
13545
13547
  if(WebsocketImplementation.isNodeContext && typeof(io)!=="undefined"){
13546
- // // Node client :
13547
- // connectToServer=function (serverURL, port, isSecure, timeout=10000){
13548
- // return Socket.connect(serverURL + ":" + port,{timeout: timeout});
13549
- // }
13550
-
13548
+
13551
13549
  // OLD SYNTAX: clientSocket=Socket.connect(serverURL + ":" + port,{timeout: timeout, secure: isSecure});
13552
13550
  // NO : clientSocket=new Socket.Client(serverURL + ":" + port,{timeout: timeout, secure: isSecure});
13553
13551
  clientSocket=io(serverURL + ":" + port,{timeout: timeout, secure: isSecure, autoConnect:true});
13554
- // DOES NOT WORK : clientSocket.connect();
13552
+ // UNUSEFUL (since we have the autoconnect:true option) : clientSocket.connect();
13555
13553
  }
13556
13554
  }
13557
13555
 
@@ -13669,7 +13667,6 @@ WebsocketImplementation={
13669
13667
  // DBG
13670
13668
  lognow("DEBUG : CLIENT : doOnConnection !");
13671
13669
 
13672
-
13673
13670
  doOnConnection(nodeClientInstance, clientSocket);
13674
13671
 
13675
13672
  // We execute the listeners entry points registration :
@@ -13730,18 +13727,9 @@ WebsocketImplementation={
13730
13727
  if(!WebsocketImplementation.useSocketIOImplementation){
13731
13728
  clientSocket=new WebSocket(serverURL+":"+port,["ws","wss"]);
13732
13729
  }else if(typeof(io)!=="undefined"){
13733
- // NOW : socket.io :
13734
- // // Browser client :
13735
- // connectToServer=function (server, port, isSecure, timeout=10000){
13736
- // return io.connect(serverURL + ":" + port,{timeout: timeout});
13737
- //// ALTERNATIVE : return io(serverURL + ":" + port,{timeout: timeout});
13738
- // };
13739
- // }else{
13740
- // // TRACE
13741
- // console.log("ERROR : Could not initialize socket !");
13742
13730
  // OLD SYNTAX :clientSocket=io.connect(serverURL + ":" + port,{timeout: timeout, secure: isSecure});
13731
+ // ALTERNATIVE :
13743
13732
  clientSocket=io(serverURL + ":" + port,{timeout: timeout, secure: isSecure});
13744
-
13745
13733
  }
13746
13734
 
13747
13735
 
aotrautils/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "aotrautils",
3
- "version": "0.0.237",
3
+ "version": "0.0.240",
4
4
  "main": "aotrautils.build.js",
5
5
  "description": "A library for vanilla javascript utils (client-side) used in aotra javascript CMS",
6
6
  "author": "Jeremie Ratomposon <info@alqemia.com> (https://alqemia.com)",