You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Scripted/website/node_modules/.cache/babel-loader/088c377a8a4c66e5b1eb62c2459...

1 line
5.9 KiB

{"ast":null,"code":"function _classCallCheck(instance, Constructor) {\n if (!(instance instanceof Constructor)) {\n throw new TypeError(\"Cannot call a class as a function\");\n }\n}\nfunction _defineProperties(target, props) {\n for (var i = 0; i < props.length; i++) {\n var descriptor = props[i];\n descriptor.enumerable = descriptor.enumerable || false;\n descriptor.configurable = true;\n if (\"value\" in descriptor) descriptor.writable = true;\n Object.defineProperty(target, descriptor.key, descriptor);\n }\n}\nfunction _createClass(Constructor, protoProps, staticProps) {\n if (protoProps) _defineProperties(Constructor.prototype, protoProps);\n if (staticProps) _defineProperties(Constructor, staticProps);\n Object.defineProperty(Constructor, \"prototype\", {\n writable: false\n });\n return Constructor;\n}\nimport { log } from \"../utils/log.js\";\nvar WebSocketClient = /*#__PURE__*/function () {\n /**\n * @param {string} url\n */\n function WebSocketClient(url) {\n _classCallCheck(this, WebSocketClient);\n this.client = new WebSocket(url);\n this.client.onerror = function (error) {\n log.error(error);\n };\n }\n /**\n * @param {(...args: any[]) => void} f\n */\n\n _createClass(WebSocketClient, [{\n key: \"onOpen\",\n value: function onOpen(f) {\n this.client.onopen = f;\n }\n /**\n * @param {(...args: any[]) => void} f\n */\n }, {\n key: \"onClose\",\n value: function onClose(f) {\n this.client.onclose = f;\n } // call f with the message string as the first argument\n\n /**\n * @param {(...args: any[]) => void} f\n */\n }, {\n key: \"onMessage\",\n value: function onMessage(f) {\n this.client.onmessage = function (e) {\n f(e.data);\n };\n }\n }]);\n return WebSocketClient;\n}();\nexport { WebSocketClient as default };","map":{"version":3,"names":["_classCallCheck","instance","Constructor","TypeError","_defineProperties","target","props","i","length","descriptor","enumerable","configurable","writable","Object","defineProperty","key","_createClass","protoProps","staticProps","prototype","log","WebSocketClient","url","client","WebSocket","onerror","error","value","onOpen","f","onopen","onClose","onclose","onMessage","onmessage","e","data","default"],"sources":["C:/Cours/SAE/SAE-3.01/Scripted/Scripted/website/node_modules/webpack-dev-server/client/clients/WebSocketClient.js"],"sourcesContent":["function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nfunction _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }\n\nfunction _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, \"prototype\", { writable: false }); return Constructor; }\n\nimport { log } from \"../utils/log.js\";\n\nvar WebSocketClient = /*#__PURE__*/function () {\n /**\n * @param {string} url\n */\n function WebSocketClient(url) {\n _classCallCheck(this, WebSocketClient);\n\n this.client = new WebSocket(url);\n\n this.client.onerror = function (error) {\n log.error(error);\n };\n }\n /**\n * @param {(...args: any[]) => void} f\n */\n\n\n _createClass(WebSocketClient, [{\n key: \"onOpen\",\n value: function onOpen(f) {\n this.client.onopen = f;\n }\n /**\n * @param {(...args: any[]) => void} f\n */\n\n }, {\n key: \"onClose\",\n value: function onClose(f) {\n this.client.onclose = f;\n } // call f with the message string as the first argument\n\n /**\n * @param {(...args: any[]) => void} f\n */\n\n }, {\n key: \"onMessage\",\n value: function onMessage(f) {\n this.client.onmessage = function (e) {\n f(e.data);\n };\n }\n }]);\n\n return WebSocketClient;\n}();\n\nexport { WebSocketClient as default };"],"mappings":"AAAA,SAASA,eAAe,CAACC,QAAQ,EAAEC,WAAW,EAAE;EAAE,IAAI,EAAED,QAAQ,YAAYC,WAAW,CAAC,EAAE;IAAE,MAAM,IAAIC,SAAS,CAAC,mCAAmC,CAAC;EAAE;AAAE;AAExJ,SAASC,iBAAiB,CAACC,MAAM,EAAEC,KAAK,EAAE;EAAE,KAAK,IAA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