node-red-contrib-tak-registration 0.11.1 → 0.11.4

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 (249) hide show
  1. package/node_modules/@types/node/LICENSE +0 -0
  2. package/node_modules/@types/node/README.md +4 -5
  3. package/node_modules/@types/node/assert/strict.d.ts +4 -4
  4. package/node_modules/@types/node/assert.d.ts +50 -26
  5. package/node_modules/@types/node/async_hooks.d.ts +13 -6
  6. package/node_modules/@types/node/buffer.d.ts +46 -38
  7. package/node_modules/@types/node/child_process.d.ts +278 -138
  8. package/node_modules/@types/node/cluster.d.ts +107 -89
  9. package/node_modules/@types/node/console.d.ts +18 -15
  10. package/node_modules/@types/node/constants.d.ts +12 -11
  11. package/node_modules/@types/node/crypto.d.ts +746 -268
  12. package/node_modules/@types/node/dgram.d.ts +82 -46
  13. package/node_modules/@types/node/diagnostics_channel.d.ts +3 -3
  14. package/node_modules/@types/node/dns/promises.d.ts +37 -26
  15. package/node_modules/@types/node/dns.d.ts +204 -63
  16. package/node_modules/@types/node/dom-events.d.ts +67 -71
  17. package/node_modules/@types/node/domain.d.ts +4 -4
  18. package/node_modules/@types/node/events.d.ts +99 -8
  19. package/node_modules/@types/node/fs/promises.d.ts +122 -85
  20. package/node_modules/@types/node/fs.d.ts +520 -316
  21. package/node_modules/@types/node/globals.d.ts +346 -286
  22. package/node_modules/@types/node/globals.global.d.ts +0 -0
  23. package/node_modules/@types/node/http.d.ts +321 -189
  24. package/node_modules/@types/node/http2.d.ts +630 -377
  25. package/node_modules/@types/node/https.d.ts +221 -112
  26. package/node_modules/@types/node/index.d.ts +0 -45
  27. package/node_modules/@types/node/inspector.d.ts +0 -1
  28. package/node_modules/@types/node/module.d.ts +75 -31
  29. package/node_modules/@types/node/net.d.ts +149 -93
  30. package/node_modules/@types/node/os.d.ts +10 -9
  31. package/node_modules/@types/node/package.json +88 -90
  32. package/node_modules/@types/node/path.d.ts +13 -13
  33. package/node_modules/@types/node/perf_hooks.d.ts +19 -18
  34. package/node_modules/@types/node/process.d.ts +170 -126
  35. package/node_modules/@types/node/punycode.d.ts +4 -4
  36. package/node_modules/@types/node/querystring.d.ts +14 -4
  37. package/node_modules/@types/node/readline/promises.d.ts +12 -7
  38. package/node_modules/@types/node/readline.d.ts +69 -56
  39. package/node_modules/@types/node/repl.d.ts +67 -61
  40. package/node_modules/@types/node/stream/consumers.d.ts +10 -10
  41. package/node_modules/@types/node/stream/promises.d.ts +56 -15
  42. package/node_modules/@types/node/stream/web.d.ts +40 -20
  43. package/node_modules/@types/node/stream.d.ts +365 -232
  44. package/node_modules/@types/node/string_decoder.d.ts +8 -8
  45. package/node_modules/@types/node/test.d.ts +133 -212
  46. package/node_modules/@types/node/timers/promises.d.ts +4 -4
  47. package/node_modules/@types/node/timers.d.ts +26 -11
  48. package/node_modules/@types/node/tls.d.ts +152 -72
  49. package/node_modules/@types/node/trace_events.d.ts +3 -3
  50. package/node_modules/@types/node/ts4.8/assert/strict.d.ts +4 -4
  51. package/node_modules/@types/node/ts4.8/assert.d.ts +50 -26
  52. package/node_modules/@types/node/ts4.8/async_hooks.d.ts +13 -6
  53. package/node_modules/@types/node/ts4.8/buffer.d.ts +47 -39
  54. package/node_modules/@types/node/ts4.8/child_process.d.ts +278 -138
  55. package/node_modules/@types/node/ts4.8/cluster.d.ts +107 -89
  56. package/node_modules/@types/node/ts4.8/console.d.ts +18 -15
  57. package/node_modules/@types/node/ts4.8/constants.d.ts +12 -11
  58. package/node_modules/@types/node/ts4.8/crypto.d.ts +746 -268
  59. package/node_modules/@types/node/ts4.8/dgram.d.ts +82 -46
  60. package/node_modules/@types/node/ts4.8/diagnostics_channel.d.ts +3 -3
  61. package/node_modules/@types/node/ts4.8/dns/promises.d.ts +37 -26
  62. package/node_modules/@types/node/ts4.8/dns.d.ts +204 -63
  63. package/node_modules/@types/node/ts4.8/dom-events.d.ts +67 -71
  64. package/node_modules/@types/node/ts4.8/domain.d.ts +4 -4
  65. package/node_modules/@types/node/ts4.8/events.d.ts +99 -8
  66. package/node_modules/@types/node/ts4.8/fs/promises.d.ts +122 -85
  67. package/node_modules/@types/node/ts4.8/fs.d.ts +520 -316
  68. package/node_modules/@types/node/ts4.8/globals.d.ts +346 -286
  69. package/node_modules/@types/node/ts4.8/globals.global.d.ts +0 -0
  70. package/node_modules/@types/node/ts4.8/http.d.ts +321 -189
  71. package/node_modules/@types/node/ts4.8/http2.d.ts +630 -377
  72. package/node_modules/@types/node/ts4.8/https.d.ts +221 -112
  73. package/node_modules/@types/node/ts4.8/index.d.ts +0 -0
  74. package/node_modules/@types/node/ts4.8/inspector.d.ts +0 -1
  75. package/node_modules/@types/node/ts4.8/module.d.ts +75 -31
  76. package/node_modules/@types/node/ts4.8/net.d.ts +149 -93
  77. package/node_modules/@types/node/ts4.8/os.d.ts +10 -9
  78. package/node_modules/@types/node/ts4.8/path.d.ts +13 -13
  79. package/node_modules/@types/node/ts4.8/perf_hooks.d.ts +19 -18
  80. package/node_modules/@types/node/ts4.8/process.d.ts +170 -126
  81. package/node_modules/@types/node/ts4.8/punycode.d.ts +4 -4
  82. package/node_modules/@types/node/ts4.8/querystring.d.ts +14 -4
  83. package/node_modules/@types/node/ts4.8/readline/promises.d.ts +12 -7
  84. package/node_modules/@types/node/ts4.8/readline.d.ts +69 -56
  85. package/node_modules/@types/node/ts4.8/repl.d.ts +67 -61
  86. package/node_modules/@types/node/ts4.8/stream/consumers.d.ts +10 -10
  87. package/node_modules/@types/node/ts4.8/stream/promises.d.ts +56 -15
  88. package/node_modules/@types/node/ts4.8/stream/web.d.ts +40 -20
  89. package/node_modules/@types/node/ts4.8/stream.d.ts +494 -223
  90. package/node_modules/@types/node/ts4.8/string_decoder.d.ts +8 -8
  91. package/node_modules/@types/node/ts4.8/test.d.ts +135 -214
  92. package/node_modules/@types/node/ts4.8/timers/promises.d.ts +4 -4
  93. package/node_modules/@types/node/ts4.8/timers.d.ts +26 -11
  94. package/node_modules/@types/node/ts4.8/tls.d.ts +152 -72
  95. package/node_modules/@types/node/ts4.8/trace_events.d.ts +3 -3
  96. package/node_modules/@types/node/ts4.8/tty.d.ts +10 -10
  97. package/node_modules/@types/node/ts4.8/url.d.ts +26 -14
  98. package/node_modules/@types/node/ts4.8/util.d.ts +187 -120
  99. package/node_modules/@types/node/ts4.8/v8.d.ts +4 -4
  100. package/node_modules/@types/node/ts4.8/vm.d.ts +58 -50
  101. package/node_modules/@types/node/ts4.8/wasi.d.ts +10 -4
  102. package/node_modules/@types/node/ts4.8/worker_threads.d.ts +83 -86
  103. package/node_modules/@types/node/ts4.8/zlib.d.ts +9 -9
  104. package/node_modules/@types/node/tty.d.ts +10 -10
  105. package/node_modules/@types/node/url.d.ts +26 -14
  106. package/node_modules/@types/node/util.d.ts +187 -120
  107. package/node_modules/@types/node/v8.d.ts +4 -4
  108. package/node_modules/@types/node/vm.d.ts +58 -50
  109. package/node_modules/@types/node/wasi.d.ts +10 -4
  110. package/node_modules/@types/node/worker_threads.d.ts +83 -86
  111. package/node_modules/@types/node/zlib.d.ts +9 -9
  112. package/node_modules/axios/CHANGELOG.md +225 -0
  113. package/node_modules/axios/README.md +273 -9
  114. package/node_modules/axios/dist/axios.js +249 -178
  115. package/node_modules/axios/dist/axios.js.map +1 -1
  116. package/node_modules/axios/dist/axios.min.js +1 -1
  117. package/node_modules/axios/dist/axios.min.js.map +1 -1
  118. package/node_modules/axios/dist/browser/axios.cjs +213 -193
  119. package/node_modules/axios/dist/browser/axios.cjs.map +1 -1
  120. package/node_modules/axios/dist/esm/axios.js +213 -193
  121. package/node_modules/axios/dist/esm/axios.js.map +1 -1
  122. package/node_modules/axios/dist/esm/axios.min.js +1 -1
  123. package/node_modules/axios/dist/esm/axios.min.js.map +1 -1
  124. package/node_modules/axios/dist/node/axios.cjs +297 -213
  125. package/node_modules/axios/dist/node/axios.cjs.map +1 -1
  126. package/node_modules/axios/index.d.cts +20 -11
  127. package/node_modules/axios/index.d.ts +21 -12
  128. package/node_modules/axios/lib/adapters/adapters.js +33 -15
  129. package/node_modules/axios/lib/adapters/http.js +25 -12
  130. package/node_modules/axios/lib/adapters/xhr.js +17 -10
  131. package/node_modules/axios/lib/core/mergeConfig.js +1 -0
  132. package/node_modules/axios/lib/defaults/index.js +1 -1
  133. package/node_modules/axios/lib/env/data.js +1 -1
  134. package/node_modules/axios/lib/helpers/cookies.js +39 -49
  135. package/node_modules/axios/lib/helpers/isURLSameOrigin.js +2 -2
  136. package/node_modules/axios/lib/platform/browser/index.js +0 -51
  137. package/node_modules/axios/lib/platform/common/utils.js +47 -0
  138. package/node_modules/axios/lib/platform/index.js +5 -1
  139. package/node_modules/axios/package.json +2 -1
  140. package/node_modules/call-bind/.eslintrc +0 -1
  141. package/node_modules/call-bind/.nycrc +0 -4
  142. package/node_modules/call-bind/CHANGELOG.md +35 -0
  143. package/node_modules/call-bind/README.md +63 -1
  144. package/node_modules/call-bind/index.js +10 -13
  145. package/node_modules/call-bind/package.json +33 -23
  146. package/node_modules/call-bind/test/callBound.js +0 -1
  147. package/node_modules/call-bind/test/index.js +18 -4
  148. package/node_modules/{function-bind → deep-equal}/.editorconfig +1 -1
  149. package/node_modules/deep-equal/.eslintrc +6 -0
  150. package/node_modules/deep-equal/.nycrc +17 -0
  151. package/node_modules/deep-equal/CHANGELOG.md +204 -4
  152. package/node_modules/deep-equal/assert.js +3 -0
  153. package/node_modules/deep-equal/package.json +39 -17
  154. package/node_modules/deep-equal/readme.markdown +28 -12
  155. package/node_modules/deep-equal/test/_tape.js +24 -3
  156. package/node_modules/deep-equal/test/cmp.js +1047 -48
  157. package/node_modules/define-data-property/CHANGELOG.md +10 -0
  158. package/node_modules/define-data-property/index.d.ts.map +1 -1
  159. package/node_modules/define-data-property/index.js +8 -0
  160. package/node_modules/define-data-property/package.json +11 -9
  161. package/node_modules/define-data-property/test/index.js +6 -11
  162. package/node_modules/define-data-property/tsconfig.json +1 -0
  163. package/node_modules/fast-xml-parser/CHANGELOG.md +11 -0
  164. package/node_modules/fast-xml-parser/package.json +5 -5
  165. package/node_modules/fast-xml-parser/src/xmlbuilder/json2xml.js +1 -0
  166. package/node_modules/fast-xml-parser/src/xmlbuilder/orderedJs2Xml.js +4 -0
  167. package/node_modules/fast-xml-parser/src/xmlparser/OrderedObjParser.js +6 -3
  168. package/node_modules/follow-redirects/index.js +16 -4
  169. package/node_modules/follow-redirects/package.json +2 -3
  170. package/node_modules/function-bind/.eslintrc +11 -5
  171. package/node_modules/function-bind/.github/FUNDING.yml +12 -0
  172. package/node_modules/function-bind/.github/SECURITY.md +3 -0
  173. package/node_modules/function-bind/.nycrc +13 -0
  174. package/node_modules/function-bind/CHANGELOG.md +136 -0
  175. package/node_modules/function-bind/README.md +25 -27
  176. package/node_modules/function-bind/implementation.js +44 -12
  177. package/node_modules/function-bind/package.json +38 -14
  178. package/node_modules/get-intrinsic/CHANGELOG.md +8 -0
  179. package/node_modules/get-intrinsic/index.js +1 -1
  180. package/node_modules/get-intrinsic/package.json +11 -11
  181. package/node_modules/has-property-descriptors/CHANGELOG.md +11 -0
  182. package/node_modules/has-property-descriptors/package.json +13 -6
  183. package/node_modules/hasown/.eslintrc +5 -0
  184. package/node_modules/hasown/.github/FUNDING.yml +12 -0
  185. package/node_modules/hasown/.nycrc +13 -0
  186. package/node_modules/hasown/CHANGELOG.md +20 -0
  187. package/node_modules/hasown/LICENSE +21 -0
  188. package/node_modules/hasown/README.md +40 -0
  189. package/node_modules/hasown/index.d.ts +3 -0
  190. package/node_modules/hasown/index.d.ts.map +1 -0
  191. package/node_modules/hasown/index.js +8 -0
  192. package/node_modules/hasown/package.json +91 -0
  193. package/node_modules/hasown/tsconfig.json +49 -0
  194. package/node_modules/set-function-length/.eslintrc +27 -0
  195. package/node_modules/set-function-length/.github/FUNDING.yml +12 -0
  196. package/node_modules/set-function-length/.nycrc +13 -0
  197. package/node_modules/set-function-length/CHANGELOG.md +41 -0
  198. package/node_modules/set-function-length/LICENSE +21 -0
  199. package/node_modules/set-function-length/README.md +56 -0
  200. package/node_modules/set-function-length/env.js +19 -0
  201. package/node_modules/set-function-length/index.js +41 -0
  202. package/node_modules/set-function-length/package.json +84 -0
  203. package/node_modules/undici-types/README.md +6 -0
  204. package/node_modules/undici-types/agent.d.ts +31 -0
  205. package/node_modules/undici-types/api.d.ts +43 -0
  206. package/node_modules/undici-types/balanced-pool.d.ts +18 -0
  207. package/node_modules/undici-types/cache.d.ts +36 -0
  208. package/node_modules/undici-types/client.d.ts +97 -0
  209. package/node_modules/undici-types/connector.d.ts +34 -0
  210. package/node_modules/undici-types/content-type.d.ts +21 -0
  211. package/node_modules/undici-types/cookies.d.ts +28 -0
  212. package/node_modules/undici-types/diagnostics-channel.d.ts +67 -0
  213. package/node_modules/undici-types/dispatcher.d.ts +241 -0
  214. package/node_modules/undici-types/errors.d.ts +128 -0
  215. package/node_modules/undici-types/fetch.d.ts +209 -0
  216. package/node_modules/undici-types/file.d.ts +39 -0
  217. package/node_modules/undici-types/filereader.d.ts +54 -0
  218. package/node_modules/undici-types/formdata.d.ts +108 -0
  219. package/node_modules/undici-types/global-dispatcher.d.ts +9 -0
  220. package/node_modules/undici-types/global-origin.d.ts +7 -0
  221. package/node_modules/undici-types/handlers.d.ts +9 -0
  222. package/node_modules/undici-types/header.d.ts +4 -0
  223. package/node_modules/undici-types/index.d.ts +63 -0
  224. package/node_modules/undici-types/interceptors.d.ts +5 -0
  225. package/node_modules/undici-types/mock-agent.d.ts +50 -0
  226. package/node_modules/undici-types/mock-client.d.ts +25 -0
  227. package/node_modules/undici-types/mock-errors.d.ts +12 -0
  228. package/node_modules/undici-types/mock-interceptor.d.ts +93 -0
  229. package/node_modules/undici-types/mock-pool.d.ts +25 -0
  230. package/node_modules/undici-types/package.json +55 -0
  231. package/node_modules/undici-types/patch.d.ts +71 -0
  232. package/node_modules/undici-types/pool-stats.d.ts +19 -0
  233. package/node_modules/undici-types/pool.d.ts +28 -0
  234. package/node_modules/undici-types/proxy-agent.d.ts +30 -0
  235. package/node_modules/undici-types/readable.d.ts +61 -0
  236. package/node_modules/undici-types/webidl.d.ts +220 -0
  237. package/node_modules/undici-types/websocket.d.ts +131 -0
  238. package/package.json +3 -3
  239. package/tak-ingest.js +39 -24
  240. package/tak-registration.html +4 -4
  241. package/node_modules/define-data-property/tsinit +0 -109
  242. package/node_modules/function-bind/.jscs.json +0 -176
  243. package/node_modules/function-bind/.npmignore +0 -22
  244. package/node_modules/function-bind/.travis.yml +0 -168
  245. package/node_modules/has/LICENSE-MIT +0 -22
  246. package/node_modules/has/README.md +0 -18
  247. package/node_modules/has/package.json +0 -48
  248. package/node_modules/has/src/index.js +0 -5
  249. package/node_modules/has/test/index.js +0 -10
@@ -0,0 +1,41 @@
1
+ # Changelog
2
+
3
+ All notable changes to this project will be documented in this file.
4
+
5
+ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/)
6
+ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
7
+
8
+ ## [v1.1.1](https://github.com/ljharb/set-function-length/compare/v1.1.0...v1.1.1) - 2023-10-19
9
+
10
+ ### Fixed
11
+
12
+ - [Fix] move `define-data-property` to runtime deps [`#2`](https://github.com/ljharb/set-function-length/issues/2)
13
+
14
+ ### Commits
15
+
16
+ - [Dev Deps] update `object-inspect`; add missing `call-bind` [`5aecf79`](https://github.com/ljharb/set-function-length/commit/5aecf79e7d6400957a5d9bd9ac20d4528908ca18)
17
+
18
+ ## [v1.1.0](https://github.com/ljharb/set-function-length/compare/v1.0.1...v1.1.0) - 2023-10-13
19
+
20
+ ### Commits
21
+
22
+ - [New] add `env` entry point [`475c87a`](https://github.com/ljharb/set-function-length/commit/475c87aa2f59b700aaed589d980624ec596acdcb)
23
+ - [Tests] add coverage with `nyc` [`14f0bf8`](https://github.com/ljharb/set-function-length/commit/14f0bf8c145ae60bf14a026420a06bb7be132c36)
24
+ - [eslint] fix linting failure [`fb516f9`](https://github.com/ljharb/set-function-length/commit/fb516f93c664057138c53559ef63c8622a093335)
25
+ - [Deps] update `define-data-property` [`d727e7c`](https://github.com/ljharb/set-function-length/commit/d727e7c6c9a40d7bf26797694e500ea68741feea)
26
+
27
+ ## [v1.0.1](https://github.com/ljharb/set-function-length/compare/v1.0.0...v1.0.1) - 2023-10-12
28
+
29
+ ### Commits
30
+
31
+ - [Refactor] use `get-intrinsic`, since it‘s in the dep graph anyways [`278a954`](https://github.com/ljharb/set-function-length/commit/278a954a06cd849051c569ff7aee56df6798933e)
32
+ - [meta] add `exports` [`72acfe5`](https://github.com/ljharb/set-function-length/commit/72acfe5a0310071fb205a72caba5ecbab24336a0)
33
+
34
+ ## v1.0.0 - 2023-10-12
35
+
36
+ ### Commits
37
+
38
+ - Initial implementation, tests, readme [`fce14e1`](https://github.com/ljharb/set-function-length/commit/fce14e17586460e4f294405173be72b6ffdf7e5f)
39
+ - Initial commit [`ca7ba85`](https://github.com/ljharb/set-function-length/commit/ca7ba857c7c283f9d26e21f14e71cd388f2cb722)
40
+ - npm init [`6a7e493`](https://github.com/ljharb/set-function-length/commit/6a7e493927736cebcaf5c1a84e69b8e6b7b744d8)
41
+ - Only apps should have lockfiles [`d2bf6c4`](https://github.com/ljharb/set-function-length/commit/d2bf6c43de8a51b02a0aa53e8d62cb50c4a2b0da)
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) Jordan Harband and contributors
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
@@ -0,0 +1,56 @@
1
+ # set-function-length <sup>[![Version Badge][npm-version-svg]][package-url]</sup>
2
+
3
+ [![github actions][actions-image]][actions-url]
4
+ [![coverage][codecov-image]][codecov-url]
5
+ [![License][license-image]][license-url]
6
+ [![Downloads][downloads-image]][downloads-url]
7
+
8
+ [![npm badge][npm-badge-png]][package-url]
9
+
10
+ Set a function’s length.
11
+
12
+ Arguments:
13
+ - `fn`: the function
14
+ - `length`: the new length. Must be an integer between 0 and 2**32.
15
+ - `loose`: Optional. If true, and the length fails to be set, do not throw. Default false.
16
+
17
+ Returns `fn`.
18
+
19
+ ## Usage
20
+
21
+ ```javascript
22
+ var setFunctionLength = require('set-function-length');
23
+ var assert = require('assert');
24
+
25
+ function zero() {}
26
+ function one(_) {}
27
+ function two(_, __) {}
28
+
29
+ assert.equal(zero.length, 0);
30
+ assert.equal(one.length, 1);
31
+ assert.equal(two.length, 2);
32
+
33
+ assert.equal(setFunctionLength(zero, 10), zero);
34
+ assert.equal(setFunctionLength(one, 11), one);
35
+ assert.equal(setFunctionLength(two, 12), two);
36
+
37
+ assert.equal(zero.length, 10);
38
+ assert.equal(one.length, 11);
39
+ assert.equal(two.length, 12);
40
+ ```
41
+
42
+ [package-url]: https://npmjs.org/package/set-function-length
43
+ [npm-version-svg]: https://versionbadg.es/ljharb/set-function-length.svg
44
+ [deps-svg]: https://david-dm.org/ljharb/set-function-length.svg
45
+ [deps-url]: https://david-dm.org/ljharb/set-function-length
46
+ [dev-deps-svg]: https://david-dm.org/ljharb/set-function-length/dev-status.svg
47
+ [dev-deps-url]: https://david-dm.org/ljharb/set-function-length#info=devDependencies
48
+ [npm-badge-png]: https://nodei.co/npm/set-function-length.png?downloads=true&stars=true
49
+ [license-image]: https://img.shields.io/npm/l/set-function-length.svg
50
+ [license-url]: LICENSE
51
+ [downloads-image]: https://img.shields.io/npm/dm/set-function-length.svg
52
+ [downloads-url]: https://npm-stat.com/charts.html?package=set-function-length
53
+ [codecov-image]: https://codecov.io/gh/ljharb/set-function-length/branch/main/graphs/badge.svg
54
+ [codecov-url]: https://app.codecov.io/gh/ljharb/set-function-length/
55
+ [actions-image]: https://img.shields.io/endpoint?url=https://github-actions-badge-u3jn4tfpocch.runkit.sh/ljharb/set-function-length
56
+ [actions-url]: https://github.com/ljharb/set-function-length/actions
@@ -0,0 +1,19 @@
1
+ 'use strict';
2
+
3
+ var gOPD = require('gopd');
4
+
5
+ var functionsHaveConfigurableLengths = gOPD && gOPD(function () {}, 'length').configurable;
6
+
7
+ var functionsHaveWritableLengths = gOPD && gOPD(function () {}, 'length').writable;
8
+
9
+ var boundFnsHaveConfigurableLengths = gOPD && gOPD(function () {}.bind(), 'length').configurable;
10
+
11
+ var boundFnsHaveWritableLengths = gOPD && gOPD(function () {}.bind(), 'length').writable;
12
+
13
+ module.exports = {
14
+ __proto__: null,
15
+ boundFnsHaveConfigurableLengths: boundFnsHaveConfigurableLengths,
16
+ boundFnsHaveWritableLengths: boundFnsHaveWritableLengths,
17
+ functionsHaveConfigurableLengths: functionsHaveConfigurableLengths,
18
+ functionsHaveWritableLengths: functionsHaveWritableLengths
19
+ };
@@ -0,0 +1,41 @@
1
+ 'use strict';
2
+
3
+ var GetIntrinsic = require('get-intrinsic');
4
+ var define = require('define-data-property');
5
+ var hasDescriptors = require('has-property-descriptors')();
6
+ var gOPD = require('gopd');
7
+
8
+ var $TypeError = GetIntrinsic('%TypeError%');
9
+ var $floor = GetIntrinsic('%Math.floor%');
10
+
11
+ module.exports = function setFunctionLength(fn, length) {
12
+ if (typeof fn !== 'function') {
13
+ throw new $TypeError('`fn` is not a function');
14
+ }
15
+ if (typeof length !== 'number' || length < 0 || length > 0xFFFFFFFF || $floor(length) !== length) {
16
+ throw new $TypeError('`length` must be a positive 32-bit integer');
17
+ }
18
+
19
+ var loose = arguments.length > 2 && !!arguments[2];
20
+
21
+ var functionLengthIsConfigurable = true;
22
+ var functionLengthIsWritable = true;
23
+ if ('length' in fn && gOPD) {
24
+ var desc = gOPD(fn, 'length');
25
+ if (desc && !desc.configurable) {
26
+ functionLengthIsConfigurable = false;
27
+ }
28
+ if (desc && !desc.writable) {
29
+ functionLengthIsWritable = false;
30
+ }
31
+ }
32
+
33
+ if (functionLengthIsConfigurable || functionLengthIsWritable || !loose) {
34
+ if (hasDescriptors) {
35
+ define(fn, 'length', length, true, true);
36
+ } else {
37
+ define(fn, 'length', length);
38
+ }
39
+ }
40
+ return fn;
41
+ };
@@ -0,0 +1,84 @@
1
+ {
2
+ "name": "set-function-length",
3
+ "version": "1.1.1",
4
+ "description": "Set a function's length property",
5
+ "main": "index.js",
6
+ "exports": {
7
+ ".": "./index.js",
8
+ "./env": "./env.js",
9
+ "./package.json": "./package.json"
10
+ },
11
+ "directories": {
12
+ "test": "test"
13
+ },
14
+ "scripts": {
15
+ "prepack": "npmignore --auto --commentLines=autogenerated",
16
+ "prepublish": "not-in-publish || npm run prepublishOnly",
17
+ "prepublishOnly": "safe-publish-latest",
18
+ "prelint": "evalmd README.md",
19
+ "lint": "eslint --ext=js,mjs .",
20
+ "pretest": "npm run lint",
21
+ "tests-only": "nyc tape 'test/**/*.js'",
22
+ "test": "npm run tests-only",
23
+ "posttest": "aud --production",
24
+ "version": "auto-changelog && git add CHANGELOG.md",
25
+ "postversion": "auto-changelog && git add CHANGELOG.md && git commit --no-edit --amend && git tag -f \"v$(node -e \"console.log(require('./package.json').version)\")\""
26
+ },
27
+ "repository": {
28
+ "type": "git",
29
+ "url": "git+https://github.com/ljharb/set-function-length.git"
30
+ },
31
+ "keywords": [
32
+ "javascript",
33
+ "ecmascript",
34
+ "set",
35
+ "function",
36
+ "length",
37
+ "function.length"
38
+ ],
39
+ "author": "Jordan Harband <ljharb@gmail.com>",
40
+ "license": "MIT",
41
+ "bugs": {
42
+ "url": "https://github.com/ljharb/set-function-length/issues"
43
+ },
44
+ "homepage": "https://github.com/ljharb/set-function-length#readme",
45
+ "devDependencies": {
46
+ "@ljharb/eslint-config": "^21.1.0",
47
+ "aud": "^2.0.3",
48
+ "auto-changelog": "^2.4.0",
49
+ "call-bind": "^1.0.4",
50
+ "es-value-fixtures": "^1.4.2",
51
+ "eslint": "=8.8.0",
52
+ "evalmd": "^0.0.19",
53
+ "for-each": "^0.3.3",
54
+ "in-publish": "^2.0.1",
55
+ "npmignore": "^0.3.0",
56
+ "nyc": "^10.3.2",
57
+ "object-inspect": "^1.13.1",
58
+ "safe-publish-latest": "^2.0.0",
59
+ "tape": "^5.7.1"
60
+ },
61
+ "dependencies": {
62
+ "define-data-property": "^1.1.1",
63
+ "get-intrinsic": "^1.2.1",
64
+ "gopd": "^1.0.1",
65
+ "has-property-descriptors": "^1.0.0"
66
+ },
67
+ "engines": {
68
+ "node": ">= 0.4"
69
+ },
70
+ "auto-changelog": {
71
+ "output": "CHANGELOG.md",
72
+ "template": "keepachangelog",
73
+ "unreleased": false,
74
+ "commitLimit": false,
75
+ "backfillLimit": false,
76
+ "hideCredit": true
77
+ },
78
+ "publishConfig": {
79
+ "ignore": [
80
+ ".github/workflows",
81
+ "test"
82
+ ]
83
+ }
84
+ }
@@ -0,0 +1,6 @@
1
+ # undici-types
2
+
3
+ This package is a dual-publish of the [undici](https://www.npmjs.com/package/undici) library types. The `undici` package **still contains types**. This package is for users who _only_ need undici types (such as for `@types/node`). It is published alongside every release of `undici`, so you can always use the same version.
4
+
5
+ - [GitHub nodejs/undici](https://github.com/nodejs/undici)
6
+ - [Undici Documentation](https://undici.nodejs.org/#/)
@@ -0,0 +1,31 @@
1
+ import { URL } from 'url'
2
+ import Pool from './pool'
3
+ import Dispatcher from "./dispatcher";
4
+
5
+ export default Agent
6
+
7
+ declare class Agent extends Dispatcher{
8
+ constructor(opts?: Agent.Options)
9
+ /** `true` after `dispatcher.close()` has been called. */
10
+ closed: boolean;
11
+ /** `true` after `dispatcher.destroyed()` has been called or `dispatcher.close()` has been called and the dispatcher shutdown has completed. */
12
+ destroyed: boolean;
13
+ /** Dispatches a request. */
14
+ dispatch(options: Agent.DispatchOptions, handler: Dispatcher.DispatchHandlers): boolean;
15
+ }
16
+
17
+ declare namespace Agent {
18
+ export interface Options extends Pool.Options {
19
+ /** Default: `(origin, opts) => new Pool(origin, opts)`. */
20
+ factory?(origin: string | URL, opts: Object): Dispatcher;
21
+ /** Integer. Default: `0` */
22
+ maxRedirections?: number;
23
+
24
+ interceptors?: { Agent?: readonly Dispatcher.DispatchInterceptor[] } & Pool.Options["interceptors"]
25
+ }
26
+
27
+ export interface DispatchOptions extends Dispatcher.DispatchOptions {
28
+ /** Integer. */
29
+ maxRedirections?: number;
30
+ }
31
+ }
@@ -0,0 +1,43 @@
1
+ import { URL, UrlObject } from 'url'
2
+ import { Duplex } from 'stream'
3
+ import Dispatcher from './dispatcher'
4
+
5
+ export {
6
+ request,
7
+ stream,
8
+ pipeline,
9
+ connect,
10
+ upgrade,
11
+ }
12
+
13
+ /** Performs an HTTP request. */
14
+ declare function request(
15
+ url: string | URL | UrlObject,
16
+ options?: { dispatcher?: Dispatcher } & Omit<Dispatcher.RequestOptions, 'origin' | 'path' | 'method'> & Partial<Pick<Dispatcher.RequestOptions, 'method'>>,
17
+ ): Promise<Dispatcher.ResponseData>;
18
+
19
+ /** A faster version of `request`. */
20
+ declare function stream(
21
+ url: string | URL | UrlObject,
22
+ options: { dispatcher?: Dispatcher } & Omit<Dispatcher.RequestOptions, 'origin' | 'path'>,
23
+ factory: Dispatcher.StreamFactory
24
+ ): Promise<Dispatcher.StreamData>;
25
+
26
+ /** For easy use with `stream.pipeline`. */
27
+ declare function pipeline(
28
+ url: string | URL | UrlObject,
29
+ options: { dispatcher?: Dispatcher } & Omit<Dispatcher.PipelineOptions, 'origin' | 'path'>,
30
+ handler: Dispatcher.PipelineHandler
31
+ ): Duplex;
32
+
33
+ /** Starts two-way communications with the requested resource. */
34
+ declare function connect(
35
+ url: string | URL | UrlObject,
36
+ options?: { dispatcher?: Dispatcher } & Omit<Dispatcher.ConnectOptions, 'origin' | 'path'>
37
+ ): Promise<Dispatcher.ConnectData>;
38
+
39
+ /** Upgrade to a different protocol. */
40
+ declare function upgrade(
41
+ url: string | URL | UrlObject,
42
+ options?: { dispatcher?: Dispatcher } & Omit<Dispatcher.UpgradeOptions, 'origin' | 'path'>
43
+ ): Promise<Dispatcher.UpgradeData>;
@@ -0,0 +1,18 @@
1
+ import Pool from './pool'
2
+ import Dispatcher from './dispatcher'
3
+ import { URL } from 'url'
4
+
5
+ export default BalancedPool
6
+
7
+ declare class BalancedPool extends Dispatcher {
8
+ constructor(url: string | string[] | URL | URL[], options?: Pool.Options);
9
+
10
+ addUpstream(upstream: string | URL): BalancedPool;
11
+ removeUpstream(upstream: string | URL): BalancedPool;
12
+ upstreams: Array<string>;
13
+
14
+ /** `true` after `pool.close()` has been called. */
15
+ closed: boolean;
16
+ /** `true` after `pool.destroyed()` has been called or `pool.close()` has been called and the pool shutdown has completed. */
17
+ destroyed: boolean;
18
+ }
@@ -0,0 +1,36 @@
1
+ import type { RequestInfo, Response, Request } from './fetch'
2
+
3
+ export interface CacheStorage {
4
+ match (request: RequestInfo, options?: MultiCacheQueryOptions): Promise<Response | undefined>,
5
+ has (cacheName: string): Promise<boolean>,
6
+ open (cacheName: string): Promise<Cache>,
7
+ delete (cacheName: string): Promise<boolean>,
8
+ keys (): Promise<string[]>
9
+ }
10
+
11
+ declare const CacheStorage: {
12
+ prototype: CacheStorage
13
+ new(): CacheStorage
14
+ }
15
+
16
+ export interface Cache {
17
+ match (request: RequestInfo, options?: CacheQueryOptions): Promise<Response | undefined>,
18
+ matchAll (request?: RequestInfo, options?: CacheQueryOptions): Promise<readonly Response[]>,
19
+ add (request: RequestInfo): Promise<undefined>,
20
+ addAll (requests: RequestInfo[]): Promise<undefined>,
21
+ put (request: RequestInfo, response: Response): Promise<undefined>,
22
+ delete (request: RequestInfo, options?: CacheQueryOptions): Promise<boolean>,
23
+ keys (request?: RequestInfo, options?: CacheQueryOptions): Promise<readonly Request[]>
24
+ }
25
+
26
+ export interface CacheQueryOptions {
27
+ ignoreSearch?: boolean,
28
+ ignoreMethod?: boolean,
29
+ ignoreVary?: boolean
30
+ }
31
+
32
+ export interface MultiCacheQueryOptions extends CacheQueryOptions {
33
+ cacheName?: string
34
+ }
35
+
36
+ export declare const caches: CacheStorage
@@ -0,0 +1,97 @@
1
+ import { URL } from 'url'
2
+ import { TlsOptions } from 'tls'
3
+ import Dispatcher from './dispatcher'
4
+ import buildConnector from "./connector";
5
+
6
+ /**
7
+ * A basic HTTP/1.1 client, mapped on top a single TCP/TLS connection. Pipelining is disabled by default.
8
+ */
9
+ export class Client extends Dispatcher {
10
+ constructor(url: string | URL, options?: Client.Options);
11
+ /** Property to get and set the pipelining factor. */
12
+ pipelining: number;
13
+ /** `true` after `client.close()` has been called. */
14
+ closed: boolean;
15
+ /** `true` after `client.destroyed()` has been called or `client.close()` has been called and the client shutdown has completed. */
16
+ destroyed: boolean;
17
+ }
18
+
19
+ export declare namespace Client {
20
+ export interface OptionsInterceptors {
21
+ Client: readonly Dispatcher.DispatchInterceptor[];
22
+ }
23
+ export interface Options {
24
+ /** TODO */
25
+ interceptors?: OptionsInterceptors;
26
+ /** The maximum length of request headers in bytes. Default: Node.js' `--max-http-header-size` or `16384` (16KiB). */
27
+ maxHeaderSize?: number;
28
+ /** The amount of time, in milliseconds, the parser will wait to receive the complete HTTP headers (Node 14 and above only). Default: `300e3` milliseconds (300s). */
29
+ headersTimeout?: number;
30
+ /** @deprecated unsupported socketTimeout, use headersTimeout & bodyTimeout instead */
31
+ socketTimeout?: never;
32
+ /** @deprecated unsupported requestTimeout, use headersTimeout & bodyTimeout instead */
33
+ requestTimeout?: never;
34
+ /** TODO */
35
+ connectTimeout?: number;
36
+ /** The timeout after which a request will time out, in milliseconds. Monitors time between receiving body data. Use `0` to disable it entirely. Default: `300e3` milliseconds (300s). */
37
+ bodyTimeout?: number;
38
+ /** @deprecated unsupported idleTimeout, use keepAliveTimeout instead */
39
+ idleTimeout?: never;
40
+ /** @deprecated unsupported keepAlive, use pipelining=0 instead */
41
+ keepAlive?: never;
42
+ /** the timeout, in milliseconds, after which a socket without active requests will time out. Monitors time between activity on a connected socket. This value may be overridden by *keep-alive* hints from the server. Default: `4e3` milliseconds (4s). */
43
+ keepAliveTimeout?: number;
44
+ /** @deprecated unsupported maxKeepAliveTimeout, use keepAliveMaxTimeout instead */
45
+ maxKeepAliveTimeout?: never;
46
+ /** the maximum allowed `idleTimeout`, in milliseconds, when overridden by *keep-alive* hints from the server. Default: `600e3` milliseconds (10min). */
47
+ keepAliveMaxTimeout?: number;
48
+ /** A number of milliseconds subtracted from server *keep-alive* hints when overriding `idleTimeout` to account for timing inaccuracies caused by e.g. transport latency. Default: `1e3` milliseconds (1s). */
49
+ keepAliveTimeoutThreshold?: number;
50
+ /** TODO */
51
+ socketPath?: string;
52
+ /** The amount of concurrent requests to be sent over the single TCP/TLS connection according to [RFC7230](https://tools.ietf.org/html/rfc7230#section-6.3.2). Default: `1`. */
53
+ pipelining?: number;
54
+ /** @deprecated use the connect option instead */
55
+ tls?: never;
56
+ /** If `true`, an error is thrown when the request content-length header doesn't match the length of the request body. Default: `true`. */
57
+ strictContentLength?: boolean;
58
+ /** TODO */
59
+ maxCachedSessions?: number;
60
+ /** TODO */
61
+ maxRedirections?: number;
62
+ /** TODO */
63
+ connect?: buildConnector.BuildOptions | buildConnector.connector;
64
+ /** TODO */
65
+ maxRequestsPerClient?: number;
66
+ /** TODO */
67
+ localAddress?: string;
68
+ /** Max response body size in bytes, -1 is disabled */
69
+ maxResponseSize?: number;
70
+ /** Enables a family autodetection algorithm that loosely implements section 5 of RFC 8305. */
71
+ autoSelectFamily?: boolean;
72
+ /** The amount of time in milliseconds to wait for a connection attempt to finish before trying the next address when using the `autoSelectFamily` option. */
73
+ autoSelectFamilyAttemptTimeout?: number;
74
+ /**
75
+ * @description Enables support for H2 if the server has assigned bigger priority to it through ALPN negotiation.
76
+ * @default false
77
+ */
78
+ allowH2?: boolean;
79
+ /**
80
+ * @description Dictates the maximum number of concurrent streams for a single H2 session. It can be overriden by a SETTINGS remote frame.
81
+ * @default 100
82
+ */
83
+ maxConcurrentStreams?: number
84
+ }
85
+ export interface SocketInfo {
86
+ localAddress?: string
87
+ localPort?: number
88
+ remoteAddress?: string
89
+ remotePort?: number
90
+ remoteFamily?: string
91
+ timeout?: number
92
+ bytesWritten?: number
93
+ bytesRead?: number
94
+ }
95
+ }
96
+
97
+ export default Client;
@@ -0,0 +1,34 @@
1
+ import { TLSSocket, ConnectionOptions } from 'tls'
2
+ import { IpcNetConnectOpts, Socket, TcpNetConnectOpts } from 'net'
3
+
4
+ export default buildConnector
5
+ declare function buildConnector (options?: buildConnector.BuildOptions): buildConnector.connector
6
+
7
+ declare namespace buildConnector {
8
+ export type BuildOptions = (ConnectionOptions | TcpNetConnectOpts | IpcNetConnectOpts) & {
9
+ allowH2?: boolean;
10
+ maxCachedSessions?: number | null;
11
+ socketPath?: string | null;
12
+ timeout?: number | null;
13
+ port?: number;
14
+ keepAlive?: boolean | null;
15
+ keepAliveInitialDelay?: number | null;
16
+ }
17
+
18
+ export interface Options {
19
+ hostname: string
20
+ host?: string
21
+ protocol: string
22
+ port: string
23
+ servername?: string
24
+ localAddress?: string | null
25
+ httpSocket?: Socket
26
+ }
27
+
28
+ export type Callback = (...args: CallbackArgs) => void
29
+ type CallbackArgs = [null, Socket | TLSSocket] | [Error, null]
30
+
31
+ export interface connector {
32
+ (options: buildConnector.Options, callback: buildConnector.Callback): void
33
+ }
34
+ }
@@ -0,0 +1,21 @@
1
+ /// <reference types="node" />
2
+
3
+ interface MIMEType {
4
+ type: string
5
+ subtype: string
6
+ parameters: Map<string, string>
7
+ essence: string
8
+ }
9
+
10
+ /**
11
+ * Parse a string to a {@link MIMEType} object. Returns `failure` if the string
12
+ * couldn't be parsed.
13
+ * @see https://mimesniff.spec.whatwg.org/#parse-a-mime-type
14
+ */
15
+ export function parseMIMEType (input: string): 'failure' | MIMEType
16
+
17
+ /**
18
+ * Convert a MIMEType object to a string.
19
+ * @see https://mimesniff.spec.whatwg.org/#serialize-a-mime-type
20
+ */
21
+ export function serializeAMimeType (mimeType: MIMEType): string
@@ -0,0 +1,28 @@
1
+ /// <reference types="node" />
2
+
3
+ import type { Headers } from './fetch'
4
+
5
+ export interface Cookie {
6
+ name: string
7
+ value: string
8
+ expires?: Date | number
9
+ maxAge?: number
10
+ domain?: string
11
+ path?: string
12
+ secure?: boolean
13
+ httpOnly?: boolean
14
+ sameSite?: 'Strict' | 'Lax' | 'None'
15
+ unparsed?: string[]
16
+ }
17
+
18
+ export function deleteCookie (
19
+ headers: Headers,
20
+ name: string,
21
+ attributes?: { name?: string, domain?: string }
22
+ ): void
23
+
24
+ export function getCookies (headers: Headers): Record<string, string>
25
+
26
+ export function getSetCookies (headers: Headers): Cookie[]
27
+
28
+ export function setCookie (headers: Headers, cookie: Cookie): void
@@ -0,0 +1,67 @@
1
+ import { Socket } from "net";
2
+ import { URL } from "url";
3
+ import Connector from "./connector";
4
+ import Dispatcher from "./dispatcher";
5
+
6
+ declare namespace DiagnosticsChannel {
7
+ interface Request {
8
+ origin?: string | URL;
9
+ completed: boolean;
10
+ method?: Dispatcher.HttpMethod;
11
+ path: string;
12
+ headers: string;
13
+ addHeader(key: string, value: string): Request;
14
+ }
15
+ interface Response {
16
+ statusCode: number;
17
+ statusText: string;
18
+ headers: Array<Buffer>;
19
+ }
20
+ type Error = unknown;
21
+ interface ConnectParams {
22
+ host: URL["host"];
23
+ hostname: URL["hostname"];
24
+ protocol: URL["protocol"];
25
+ port: URL["port"];
26
+ servername: string | null;
27
+ }
28
+ type Connector = Connector.connector;
29
+ export interface RequestCreateMessage {
30
+ request: Request;
31
+ }
32
+ export interface RequestBodySentMessage {
33
+ request: Request;
34
+ }
35
+ export interface RequestHeadersMessage {
36
+ request: Request;
37
+ response: Response;
38
+ }
39
+ export interface RequestTrailersMessage {
40
+ request: Request;
41
+ trailers: Array<Buffer>;
42
+ }
43
+ export interface RequestErrorMessage {
44
+ request: Request;
45
+ error: Error;
46
+ }
47
+ export interface ClientSendHeadersMessage {
48
+ request: Request;
49
+ headers: string;
50
+ socket: Socket;
51
+ }
52
+ export interface ClientBeforeConnectMessage {
53
+ connectParams: ConnectParams;
54
+ connector: Connector;
55
+ }
56
+ export interface ClientConnectedMessage {
57
+ socket: Socket;
58
+ connectParams: ConnectParams;
59
+ connector: Connector;
60
+ }
61
+ export interface ClientConnectErrorMessage {
62
+ error: Error;
63
+ socket: Socket;
64
+ connectParams: ConnectParams;
65
+ connector: Connector;
66
+ }
67
+ }