@smthrs/platform-bun 0.0.0-stage → 1.0.0-rc.13

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 (429) hide show
  1. package/CHANGELOG.md +73 -0
  2. package/LICENSE +21 -0
  3. package/README.md +110 -2
  4. package/dist/cjs/BunFileSystem.d.ts +44 -0
  5. package/dist/cjs/BunFileSystem.d.ts.map +1 -0
  6. package/dist/cjs/BunFileSystem.js +38 -0
  7. package/dist/cjs/BunFileSystem.js.map +7 -0
  8. package/dist/cjs/BunHost.d.ts +205 -0
  9. package/dist/cjs/BunHost.d.ts.map +1 -0
  10. package/dist/cjs/BunHost.js +148 -0
  11. package/dist/cjs/BunHost.js.map +7 -0
  12. package/dist/cjs/index.d.ts +26 -0
  13. package/dist/cjs/index.d.ts.map +1 -0
  14. package/dist/cjs/index.js +37 -0
  15. package/dist/cjs/index.js.map +7 -0
  16. package/dist/cjs/package.json +1 -0
  17. package/dist/esm/BunFileSystem.d.ts +44 -0
  18. package/dist/esm/BunFileSystem.d.ts.map +1 -0
  19. package/dist/esm/BunFileSystem.js +35 -0
  20. package/dist/esm/BunFileSystem.js.map +1 -0
  21. package/dist/esm/BunHost.d.ts +205 -0
  22. package/dist/esm/BunHost.d.ts.map +1 -0
  23. package/dist/esm/BunHost.js +248 -0
  24. package/dist/esm/BunHost.js.map +1 -0
  25. package/dist/esm/index.d.ts +26 -0
  26. package/dist/esm/index.d.ts.map +1 -0
  27. package/dist/esm/index.js +26 -0
  28. package/dist/esm/index.js.map +1 -0
  29. package/dist/vendor/adapters.json +3067 -0
  30. package/dist/vendor/bun/BunAddressResolver.d.ts +15 -0
  31. package/dist/vendor/bun/BunAddressResolver.js +8 -0
  32. package/dist/vendor/bun/BunChildProcessSpawner.d.ts +8 -0
  33. package/dist/vendor/bun/BunChildProcessSpawner.js +14 -0
  34. package/dist/vendor/bun/BunClusterHttp.d.ts +76 -0
  35. package/dist/vendor/bun/BunClusterHttp.js +39 -0
  36. package/dist/vendor/bun/BunClusterSocket.d.ts +70 -0
  37. package/dist/vendor/bun/BunClusterSocket.js +22 -0
  38. package/dist/vendor/bun/BunCrypto.d.ts +11 -0
  39. package/dist/vendor/bun/BunCrypto.js +8 -0
  40. package/dist/vendor/bun/BunDatagramSocket.d.ts +227 -0
  41. package/dist/vendor/bun/BunDatagramSocket.js +11 -0
  42. package/dist/vendor/bun/BunDns.d.ts +72 -0
  43. package/dist/vendor/bun/BunDns.js +12 -0
  44. package/dist/vendor/bun/BunFileSystem.d.ts +11 -0
  45. package/dist/vendor/bun/BunFileSystem.js +9 -0
  46. package/dist/vendor/bun/BunHttpClient.d.ts +10 -0
  47. package/dist/vendor/bun/BunHttpClient.js +1 -0
  48. package/dist/vendor/bun/BunHttpPlatform.d.ts +11 -0
  49. package/dist/vendor/bun/BunHttpPlatform.js +11 -0
  50. package/dist/vendor/bun/BunHttpServer.d.ts +151 -0
  51. package/dist/vendor/bun/BunHttpServer.js +38 -0
  52. package/dist/vendor/bun/BunHttpServerRequest.d.ts +20 -0
  53. package/dist/vendor/bun/BunHttpServerRequest.js +7 -0
  54. package/dist/vendor/bun/BunMultipart.d.ts +34 -0
  55. package/dist/vendor/bun/BunMultipart.js +12 -0
  56. package/dist/vendor/bun/BunPath.d.ts +27 -0
  57. package/dist/vendor/bun/BunPath.js +12 -0
  58. package/dist/vendor/bun/BunRedis.d.ts +53 -0
  59. package/dist/vendor/bun/BunRedis.js +11 -0
  60. package/dist/vendor/bun/BunRuntime.d.ts +88 -0
  61. package/dist/vendor/bun/BunRuntime.js +8 -0
  62. package/dist/vendor/bun/BunServices.d.ts +37 -0
  63. package/dist/vendor/bun/BunServices.js +23 -0
  64. package/dist/vendor/bun/BunSink.d.ts +9 -0
  65. package/dist/vendor/bun/BunSink.js +12 -0
  66. package/dist/vendor/bun/BunSocket.d.ts +45 -0
  67. package/dist/vendor/bun/BunSocket.js +29 -0
  68. package/dist/vendor/bun/BunSocketServer.d.ts +9 -0
  69. package/dist/vendor/bun/BunSocketServer.js +21 -0
  70. package/dist/vendor/bun/BunStdio.d.ts +12 -0
  71. package/dist/vendor/bun/BunStdio.js +10 -0
  72. package/dist/vendor/bun/BunStream.d.ts +20 -0
  73. package/dist/vendor/bun/BunStream.js +30 -0
  74. package/dist/vendor/bun/BunTerminal.d.ts +24 -0
  75. package/dist/vendor/bun/BunTerminal.js +10 -0
  76. package/dist/vendor/bun/BunWorker.d.ts +22 -0
  77. package/dist/vendor/bun/BunWorker.js +9 -0
  78. package/dist/vendor/bun/BunWorkerRunner.d.ts +13 -0
  79. package/dist/vendor/bun/BunWorkerRunner.js +7 -0
  80. package/dist/vendor/bun/LICENSE +21 -0
  81. package/dist/vendor/bun/index.d.ts +130 -0
  82. package/dist/vendor/bun/index.js +121 -0
  83. package/dist/vendor/chunk-226TYKP6.js +60 -0
  84. package/dist/vendor/chunk-2ADOI6ZN.js +18 -0
  85. package/dist/vendor/chunk-2AP6TO77.js +71 -0
  86. package/dist/vendor/chunk-2LGUVSNM.js +20 -0
  87. package/dist/vendor/chunk-3SUO3TTE.js +40 -0
  88. package/dist/vendor/chunk-4O4Z52A2.js +48 -0
  89. package/dist/vendor/chunk-4YK2MHSO.js +20 -0
  90. package/dist/vendor/chunk-6B775XB2.js +85 -0
  91. package/dist/vendor/chunk-6KYVM2ZC.js +419 -0
  92. package/dist/vendor/chunk-6QPSLCUZ.js +0 -0
  93. package/dist/vendor/chunk-6R444NFO.js +104 -0
  94. package/dist/vendor/chunk-7JOAEKDV.js +503 -0
  95. package/dist/vendor/chunk-7VJC3PHX.js +63 -0
  96. package/dist/vendor/chunk-7ZKNPDTP.js +26 -0
  97. package/dist/vendor/chunk-ABPRHPJP.js +15 -0
  98. package/dist/vendor/chunk-AMAL6TRE.js +93 -0
  99. package/dist/vendor/chunk-AW6WQVI7.js +29 -0
  100. package/dist/vendor/chunk-BHV44Z6K.js +36 -0
  101. package/dist/vendor/chunk-BIR74JJK.js +93 -0
  102. package/dist/vendor/chunk-BTXZUHUI.js +7 -0
  103. package/dist/vendor/chunk-BVV46N3V.js +515 -0
  104. package/dist/vendor/chunk-C7UMBJO6.js +31 -0
  105. package/dist/vendor/chunk-CN4K2U6M.js +20 -0
  106. package/dist/vendor/chunk-D6XNHJPW.js +18 -0
  107. package/dist/vendor/chunk-DHTPLWAP.js +34 -0
  108. package/dist/vendor/chunk-DWSNOBD4.js +18 -0
  109. package/dist/vendor/chunk-DX4VFONH.js +81 -0
  110. package/dist/vendor/chunk-EIO7BKW3.js +63 -0
  111. package/dist/vendor/chunk-FIPFWLCV.js +144 -0
  112. package/dist/vendor/chunk-GITB76ZP.js +22 -0
  113. package/dist/vendor/chunk-GMORYZG4.js +62 -0
  114. package/dist/vendor/chunk-HXGVOKHF.js +22 -0
  115. package/dist/vendor/chunk-HYPKWCVW.js +374 -0
  116. package/dist/vendor/chunk-IJON5WTO.js +34 -0
  117. package/dist/vendor/chunk-IXI7RW3A.js +580 -0
  118. package/dist/vendor/chunk-J43O5GFH.js +28 -0
  119. package/dist/vendor/chunk-JTST2Z7N.js +58 -0
  120. package/dist/vendor/chunk-JYD572EF.js +18 -0
  121. package/dist/vendor/chunk-K6GWBGJM.js +16 -0
  122. package/dist/vendor/chunk-KANNAI65.js +62 -0
  123. package/dist/vendor/chunk-KEMBVIRS.js +128 -0
  124. package/dist/vendor/chunk-LOB26XOO.js +0 -0
  125. package/dist/vendor/chunk-M2QOSF47.js +53 -0
  126. package/dist/vendor/chunk-MLKGABMK.js +9 -0
  127. package/dist/vendor/chunk-NGGMPIWR.js +65 -0
  128. package/dist/vendor/chunk-NNTJGFLB.js +21 -0
  129. package/dist/vendor/chunk-NU53DHQR.js +18 -0
  130. package/dist/vendor/chunk-OAY4MA3I.js +28 -0
  131. package/dist/vendor/chunk-OV2KKGBA.js +16 -0
  132. package/dist/vendor/chunk-PBM2HJOX.js +118 -0
  133. package/dist/vendor/chunk-Q5UCOQNO.js +70 -0
  134. package/dist/vendor/chunk-Q7YXUH7M.js +414 -0
  135. package/dist/vendor/chunk-QKYYD3AZ.js +131 -0
  136. package/dist/vendor/chunk-QLI7T34M.js +18 -0
  137. package/dist/vendor/chunk-QR2ZOVOL.js +18 -0
  138. package/dist/vendor/chunk-R2PFJKSP.js +274 -0
  139. package/dist/vendor/chunk-RX5TKFP7.js +51 -0
  140. package/dist/vendor/chunk-S3MN5OXB.js +34 -0
  141. package/dist/vendor/chunk-T5WDTZCE.js +249 -0
  142. package/dist/vendor/chunk-TBMTA5LD.js +14 -0
  143. package/dist/vendor/chunk-TCKM3JXD.js +325 -0
  144. package/dist/vendor/chunk-UXIG7ALP.js +229 -0
  145. package/dist/vendor/chunk-V577GRCI.js +438 -0
  146. package/dist/vendor/chunk-VS6VBUH6.js +57 -0
  147. package/dist/vendor/chunk-WGUQHMX2.js +18 -0
  148. package/dist/vendor/chunk-WNS3OER2.js +18 -0
  149. package/dist/vendor/chunk-X6FYP2EH.js +109 -0
  150. package/dist/vendor/chunk-XAVBQY4D.js +20 -0
  151. package/dist/vendor/chunk-XAZH2ZEU.js +43 -0
  152. package/dist/vendor/chunk-XDPP24MG.js +129 -0
  153. package/dist/vendor/chunk-XF3WZCMZ.js +26 -0
  154. package/dist/vendor/chunk-XXVMTKX5.js +0 -0
  155. package/dist/vendor/chunk-YJGNV6EV.js +85 -0
  156. package/dist/vendor/chunk-ZJEHEPDQ.js +18 -0
  157. package/dist/vendor/cjs/bun/BunAddressResolver.d.ts +15 -0
  158. package/dist/vendor/cjs/bun/BunAddressResolver.js +1 -0
  159. package/dist/vendor/cjs/bun/BunChildProcessSpawner.d.ts +8 -0
  160. package/dist/vendor/cjs/bun/BunChildProcessSpawner.js +1 -0
  161. package/dist/vendor/cjs/bun/BunClusterHttp.d.ts +76 -0
  162. package/dist/vendor/cjs/bun/BunClusterHttp.js +1 -0
  163. package/dist/vendor/cjs/bun/BunClusterSocket.d.ts +70 -0
  164. package/dist/vendor/cjs/bun/BunClusterSocket.js +1 -0
  165. package/dist/vendor/cjs/bun/BunCrypto.d.ts +11 -0
  166. package/dist/vendor/cjs/bun/BunCrypto.js +1 -0
  167. package/dist/vendor/cjs/bun/BunDatagramSocket.d.ts +227 -0
  168. package/dist/vendor/cjs/bun/BunDatagramSocket.js +1 -0
  169. package/dist/vendor/cjs/bun/BunDns.d.ts +72 -0
  170. package/dist/vendor/cjs/bun/BunDns.js +1 -0
  171. package/dist/vendor/cjs/bun/BunFileSystem.d.ts +11 -0
  172. package/dist/vendor/cjs/bun/BunFileSystem.js +1 -0
  173. package/dist/vendor/cjs/bun/BunHttpClient.d.ts +10 -0
  174. package/dist/vendor/cjs/bun/BunHttpClient.js +1 -0
  175. package/dist/vendor/cjs/bun/BunHttpPlatform.d.ts +11 -0
  176. package/dist/vendor/cjs/bun/BunHttpPlatform.js +1 -0
  177. package/dist/vendor/cjs/bun/BunHttpServer.d.ts +151 -0
  178. package/dist/vendor/cjs/bun/BunHttpServer.js +1 -0
  179. package/dist/vendor/cjs/bun/BunHttpServerRequest.d.ts +20 -0
  180. package/dist/vendor/cjs/bun/BunHttpServerRequest.js +1 -0
  181. package/dist/vendor/cjs/bun/BunMultipart.d.ts +34 -0
  182. package/dist/vendor/cjs/bun/BunMultipart.js +1 -0
  183. package/dist/vendor/cjs/bun/BunPath.d.ts +27 -0
  184. package/dist/vendor/cjs/bun/BunPath.js +1 -0
  185. package/dist/vendor/cjs/bun/BunRedis.d.ts +53 -0
  186. package/dist/vendor/cjs/bun/BunRedis.js +1 -0
  187. package/dist/vendor/cjs/bun/BunRuntime.d.ts +88 -0
  188. package/dist/vendor/cjs/bun/BunRuntime.js +1 -0
  189. package/dist/vendor/cjs/bun/BunServices.d.ts +37 -0
  190. package/dist/vendor/cjs/bun/BunServices.js +1 -0
  191. package/dist/vendor/cjs/bun/BunSink.d.ts +9 -0
  192. package/dist/vendor/cjs/bun/BunSink.js +1 -0
  193. package/dist/vendor/cjs/bun/BunSocket.d.ts +45 -0
  194. package/dist/vendor/cjs/bun/BunSocket.js +1 -0
  195. package/dist/vendor/cjs/bun/BunSocketServer.d.ts +9 -0
  196. package/dist/vendor/cjs/bun/BunSocketServer.js +1 -0
  197. package/dist/vendor/cjs/bun/BunStdio.d.ts +12 -0
  198. package/dist/vendor/cjs/bun/BunStdio.js +1 -0
  199. package/dist/vendor/cjs/bun/BunStream.d.ts +20 -0
  200. package/dist/vendor/cjs/bun/BunStream.js +1 -0
  201. package/dist/vendor/cjs/bun/BunTerminal.d.ts +24 -0
  202. package/dist/vendor/cjs/bun/BunTerminal.js +1 -0
  203. package/dist/vendor/cjs/bun/BunWorker.d.ts +22 -0
  204. package/dist/vendor/cjs/bun/BunWorker.js +1 -0
  205. package/dist/vendor/cjs/bun/BunWorkerRunner.d.ts +13 -0
  206. package/dist/vendor/cjs/bun/BunWorkerRunner.js +1 -0
  207. package/dist/vendor/cjs/bun/index.d.ts +130 -0
  208. package/dist/vendor/cjs/bun/index.js +1 -0
  209. package/dist/vendor/cjs/node/NodeAddressResolver.d.ts +16 -0
  210. package/dist/vendor/cjs/node/NodeAddressResolver.js +1 -0
  211. package/dist/vendor/cjs/node/NodeChildProcessSpawner.d.ts +8 -0
  212. package/dist/vendor/cjs/node/NodeChildProcessSpawner.js +1 -0
  213. package/dist/vendor/cjs/node/NodeClusterHttp.d.ts +54 -0
  214. package/dist/vendor/cjs/node/NodeClusterHttp.js +1 -0
  215. package/dist/vendor/cjs/node/NodeClusterSocket.d.ts +85 -0
  216. package/dist/vendor/cjs/node/NodeClusterSocket.js +1 -0
  217. package/dist/vendor/cjs/node/NodeCrypto.d.ts +11 -0
  218. package/dist/vendor/cjs/node/NodeCrypto.js +1 -0
  219. package/dist/vendor/cjs/node/NodeDatagramSocket.d.ts +10 -0
  220. package/dist/vendor/cjs/node/NodeDatagramSocket.js +1 -0
  221. package/dist/vendor/cjs/node/NodeDns.d.ts +51 -0
  222. package/dist/vendor/cjs/node/NodeDns.js +1 -0
  223. package/dist/vendor/cjs/node/NodeFileSystem.d.ts +11 -0
  224. package/dist/vendor/cjs/node/NodeFileSystem.js +1 -0
  225. package/dist/vendor/cjs/node/NodeHttpClient.d.ts +303 -0
  226. package/dist/vendor/cjs/node/NodeHttpClient.js +1 -0
  227. package/dist/vendor/cjs/node/NodeHttpIncomingMessage.d.ts +64 -0
  228. package/dist/vendor/cjs/node/NodeHttpIncomingMessage.js +1 -0
  229. package/dist/vendor/cjs/node/NodeHttpPlatform.d.ts +38 -0
  230. package/dist/vendor/cjs/node/NodeHttpPlatform.js +1 -0
  231. package/dist/vendor/cjs/node/NodeHttpServer.d.ts +131 -0
  232. package/dist/vendor/cjs/node/NodeHttpServer.js +1 -0
  233. package/dist/vendor/cjs/node/NodeHttpServerRequest.d.ts +32 -0
  234. package/dist/vendor/cjs/node/NodeHttpServerRequest.js +1 -0
  235. package/dist/vendor/cjs/node/NodeMultipart.d.ts +50 -0
  236. package/dist/vendor/cjs/node/NodeMultipart.js +1 -0
  237. package/dist/vendor/cjs/node/NodeMultipartParser.d.ts +105 -0
  238. package/dist/vendor/cjs/node/NodeMultipartParser.js +1 -0
  239. package/dist/vendor/cjs/node/NodePath.d.ts +30 -0
  240. package/dist/vendor/cjs/node/NodePath.js +1 -0
  241. package/dist/vendor/cjs/node/NodeRedis.d.ts +78 -0
  242. package/dist/vendor/cjs/node/NodeRedis.js +1 -0
  243. package/dist/vendor/cjs/node/NodeRuntime.d.ts +88 -0
  244. package/dist/vendor/cjs/node/NodeRuntime.js +1 -0
  245. package/dist/vendor/cjs/node/NodeServices.d.ts +37 -0
  246. package/dist/vendor/cjs/node/NodeServices.js +1 -0
  247. package/dist/vendor/cjs/node/NodeSink.d.ts +9 -0
  248. package/dist/vendor/cjs/node/NodeSink.js +1 -0
  249. package/dist/vendor/cjs/node/NodeSocket.d.ts +45 -0
  250. package/dist/vendor/cjs/node/NodeSocket.js +1 -0
  251. package/dist/vendor/cjs/node/NodeSocketServer.d.ts +9 -0
  252. package/dist/vendor/cjs/node/NodeSocketServer.js +1 -0
  253. package/dist/vendor/cjs/node/NodeStdio.d.ts +12 -0
  254. package/dist/vendor/cjs/node/NodeStdio.js +1 -0
  255. package/dist/vendor/cjs/node/NodeStream.d.ts +9 -0
  256. package/dist/vendor/cjs/node/NodeStream.js +1 -0
  257. package/dist/vendor/cjs/node/NodeTerminal.d.ts +24 -0
  258. package/dist/vendor/cjs/node/NodeTerminal.js +1 -0
  259. package/dist/vendor/cjs/node/NodeWorker.d.ts +24 -0
  260. package/dist/vendor/cjs/node/NodeWorker.js +1 -0
  261. package/dist/vendor/cjs/node/NodeWorkerRunner.d.ts +13 -0
  262. package/dist/vendor/cjs/node/NodeWorkerRunner.js +1 -0
  263. package/dist/vendor/cjs/node/Undici.d.ts +31 -0
  264. package/dist/vendor/cjs/node/Undici.js +1 -0
  265. package/dist/vendor/cjs/node/index.d.ts +140 -0
  266. package/dist/vendor/cjs/node/index.js +1 -0
  267. package/dist/vendor/cjs/node-shared/NodeAddressResolver.d.ts +13 -0
  268. package/dist/vendor/cjs/node-shared/NodeAddressResolver.js +1 -0
  269. package/dist/vendor/cjs/node-shared/NodeChildProcessSpawner.d.ts +66 -0
  270. package/dist/vendor/cjs/node-shared/NodeChildProcessSpawner.js +1 -0
  271. package/dist/vendor/cjs/node-shared/NodeClusterSocket.d.ts +35 -0
  272. package/dist/vendor/cjs/node-shared/NodeClusterSocket.js +1 -0
  273. package/dist/vendor/cjs/node-shared/NodeCrypto.d.ts +30 -0
  274. package/dist/vendor/cjs/node-shared/NodeCrypto.js +1 -0
  275. package/dist/vendor/cjs/node-shared/NodeDatagramSocket.d.ts +246 -0
  276. package/dist/vendor/cjs/node-shared/NodeDatagramSocket.js +1 -0
  277. package/dist/vendor/cjs/node-shared/NodeDns.d.ts +221 -0
  278. package/dist/vendor/cjs/node-shared/NodeDns.js +1 -0
  279. package/dist/vendor/cjs/node-shared/NodeFileSystem.d.ts +12 -0
  280. package/dist/vendor/cjs/node-shared/NodeFileSystem.js +1 -0
  281. package/dist/vendor/cjs/node-shared/NodeHttpCompression.d.ts +40 -0
  282. package/dist/vendor/cjs/node-shared/NodeHttpCompression.js +1 -0
  283. package/dist/vendor/cjs/node-shared/NodePath.d.ts +30 -0
  284. package/dist/vendor/cjs/node-shared/NodePath.js +1 -0
  285. package/dist/vendor/cjs/node-shared/NodeRuntime.d.ts +51 -0
  286. package/dist/vendor/cjs/node-shared/NodeRuntime.js +1 -0
  287. package/dist/vendor/cjs/node-shared/NodeSink.d.ts +73 -0
  288. package/dist/vendor/cjs/node-shared/NodeSink.js +1 -0
  289. package/dist/vendor/cjs/node-shared/NodeSocket.d.ts +144 -0
  290. package/dist/vendor/cjs/node-shared/NodeSocket.js +1 -0
  291. package/dist/vendor/cjs/node-shared/NodeSocketServer.d.ts +87 -0
  292. package/dist/vendor/cjs/node-shared/NodeSocketServer.js +1 -0
  293. package/dist/vendor/cjs/node-shared/NodeStdio.d.ts +13 -0
  294. package/dist/vendor/cjs/node-shared/NodeStdio.js +1 -0
  295. package/dist/vendor/cjs/node-shared/NodeStream.d.ts +194 -0
  296. package/dist/vendor/cjs/node-shared/NodeStream.js +1 -0
  297. package/dist/vendor/cjs/node-shared/NodeTerminal.d.ts +24 -0
  298. package/dist/vendor/cjs/node-shared/NodeTerminal.js +1 -0
  299. package/dist/vendor/cjs/node-shared/index.d.ts +85 -0
  300. package/dist/vendor/cjs/node-shared/index.js +1 -0
  301. package/dist/vendor/cjs/node-shared/internal/nodeChildProcessSpawner.d.ts +4 -0
  302. package/dist/vendor/cjs/node-shared/internal/nodeChildProcessSpawner.js +1 -0
  303. package/dist/vendor/cjs/node-shared/internal/utils.d.ts +2 -0
  304. package/dist/vendor/cjs/node-shared/internal/utils.js +1 -0
  305. package/dist/vendor/cjs/package.json +1 -0
  306. package/dist/vendor/cjs/platform-bun.d.ts +130 -0
  307. package/dist/vendor/cjs/platform-bun.js +1 -0
  308. package/dist/vendor/cjs/platform-node-shared.d.ts +85 -0
  309. package/dist/vendor/cjs/platform-node-shared.js +1 -0
  310. package/dist/vendor/cjs/platform-node.d.ts +140 -0
  311. package/dist/vendor/cjs/platform-node.js +1 -0
  312. package/dist/vendor/node/LICENSE +21 -0
  313. package/dist/vendor/node/NodeAddressResolver.d.ts +16 -0
  314. package/dist/vendor/node/NodeAddressResolver.js +8 -0
  315. package/dist/vendor/node/NodeChildProcessSpawner.d.ts +8 -0
  316. package/dist/vendor/node/NodeChildProcessSpawner.js +14 -0
  317. package/dist/vendor/node/NodeClusterHttp.d.ts +54 -0
  318. package/dist/vendor/node/NodeClusterHttp.js +43 -0
  319. package/dist/vendor/node/NodeClusterSocket.d.ts +85 -0
  320. package/dist/vendor/node/NodeClusterSocket.js +30 -0
  321. package/dist/vendor/node/NodeCrypto.d.ts +11 -0
  322. package/dist/vendor/node/NodeCrypto.js +8 -0
  323. package/dist/vendor/node/NodeDatagramSocket.d.ts +10 -0
  324. package/dist/vendor/node/NodeDatagramSocket.js +12 -0
  325. package/dist/vendor/node/NodeDns.d.ts +51 -0
  326. package/dist/vendor/node/NodeDns.js +12 -0
  327. package/dist/vendor/node/NodeFileSystem.d.ts +11 -0
  328. package/dist/vendor/node/NodeFileSystem.js +9 -0
  329. package/dist/vendor/node/NodeHttpClient.d.ts +303 -0
  330. package/dist/vendor/node/NodeHttpClient.js +54 -0
  331. package/dist/vendor/node/NodeHttpIncomingMessage.d.ts +64 -0
  332. package/dist/vendor/node/NodeHttpIncomingMessage.js +10 -0
  333. package/dist/vendor/node/NodeHttpPlatform.d.ts +38 -0
  334. package/dist/vendor/node/NodeHttpPlatform.js +16 -0
  335. package/dist/vendor/node/NodeHttpServer.d.ts +131 -0
  336. package/dist/vendor/node/NodeHttpServer.js +46 -0
  337. package/dist/vendor/node/NodeHttpServerRequest.d.ts +32 -0
  338. package/dist/vendor/node/NodeHttpServerRequest.js +9 -0
  339. package/dist/vendor/node/NodeMultipart.d.ts +50 -0
  340. package/dist/vendor/node/NodeMultipart.js +15 -0
  341. package/dist/vendor/node/NodeMultipartParser.d.ts +105 -0
  342. package/dist/vendor/node/NodeMultipartParser.js +11 -0
  343. package/dist/vendor/node/NodePath.d.ts +30 -0
  344. package/dist/vendor/node/NodePath.js +12 -0
  345. package/dist/vendor/node/NodeRedis.d.ts +78 -0
  346. package/dist/vendor/node/NodeRedis.js +11 -0
  347. package/dist/vendor/node/NodeRuntime.d.ts +88 -0
  348. package/dist/vendor/node/NodeRuntime.js +8 -0
  349. package/dist/vendor/node/NodeServices.d.ts +37 -0
  350. package/dist/vendor/node/NodeServices.js +23 -0
  351. package/dist/vendor/node/NodeSink.d.ts +9 -0
  352. package/dist/vendor/node/NodeSink.js +12 -0
  353. package/dist/vendor/node/NodeSocket.d.ts +45 -0
  354. package/dist/vendor/node/NodeSocket.js +31 -0
  355. package/dist/vendor/node/NodeSocketServer.d.ts +9 -0
  356. package/dist/vendor/node/NodeSocketServer.js +21 -0
  357. package/dist/vendor/node/NodeStdio.d.ts +12 -0
  358. package/dist/vendor/node/NodeStdio.js +10 -0
  359. package/dist/vendor/node/NodeStream.d.ts +9 -0
  360. package/dist/vendor/node/NodeStream.js +27 -0
  361. package/dist/vendor/node/NodeTerminal.d.ts +24 -0
  362. package/dist/vendor/node/NodeTerminal.js +10 -0
  363. package/dist/vendor/node/NodeWorker.d.ts +24 -0
  364. package/dist/vendor/node/NodeWorker.js +9 -0
  365. package/dist/vendor/node/NodeWorkerRunner.d.ts +13 -0
  366. package/dist/vendor/node/NodeWorkerRunner.js +7 -0
  367. package/dist/vendor/node/Undici.d.ts +31 -0
  368. package/dist/vendor/node/Undici.js +9 -0
  369. package/dist/vendor/node/index.d.ts +140 -0
  370. package/dist/vendor/node/index.js +130 -0
  371. package/dist/vendor/node-shared/LICENSE +21 -0
  372. package/dist/vendor/node-shared/NodeAddressResolver.d.ts +13 -0
  373. package/dist/vendor/node-shared/NodeAddressResolver.js +7 -0
  374. package/dist/vendor/node-shared/NodeChildProcessSpawner.d.ts +66 -0
  375. package/dist/vendor/node-shared/NodeChildProcessSpawner.js +13 -0
  376. package/dist/vendor/node-shared/NodeClusterSocket.d.ts +35 -0
  377. package/dist/vendor/node-shared/NodeClusterSocket.js +11 -0
  378. package/dist/vendor/node-shared/NodeCrypto.d.ts +30 -0
  379. package/dist/vendor/node-shared/NodeCrypto.js +9 -0
  380. package/dist/vendor/node-shared/NodeDatagramSocket.d.ts +246 -0
  381. package/dist/vendor/node-shared/NodeDatagramSocket.js +11 -0
  382. package/dist/vendor/node-shared/NodeDns.d.ts +221 -0
  383. package/dist/vendor/node-shared/NodeDns.js +31 -0
  384. package/dist/vendor/node-shared/NodeFileSystem.d.ts +12 -0
  385. package/dist/vendor/node-shared/NodeFileSystem.js +8 -0
  386. package/dist/vendor/node-shared/NodeHttpCompression.d.ts +40 -0
  387. package/dist/vendor/node-shared/NodeHttpCompression.js +13 -0
  388. package/dist/vendor/node-shared/NodePath.d.ts +30 -0
  389. package/dist/vendor/node-shared/NodePath.js +11 -0
  390. package/dist/vendor/node-shared/NodeRuntime.d.ts +51 -0
  391. package/dist/vendor/node-shared/NodeRuntime.js +7 -0
  392. package/dist/vendor/node-shared/NodeSink.d.ts +73 -0
  393. package/dist/vendor/node-shared/NodeSink.js +11 -0
  394. package/dist/vendor/node-shared/NodeSocket.d.ts +144 -0
  395. package/dist/vendor/node-shared/NodeSocket.js +23 -0
  396. package/dist/vendor/node-shared/NodeSocketServer.d.ts +87 -0
  397. package/dist/vendor/node-shared/NodeSocketServer.js +20 -0
  398. package/dist/vendor/node-shared/NodeStdio.d.ts +13 -0
  399. package/dist/vendor/node-shared/NodeStdio.js +9 -0
  400. package/dist/vendor/node-shared/NodeStream.d.ts +194 -0
  401. package/dist/vendor/node-shared/NodeStream.js +26 -0
  402. package/dist/vendor/node-shared/NodeTerminal.d.ts +24 -0
  403. package/dist/vendor/node-shared/NodeTerminal.js +9 -0
  404. package/dist/vendor/node-shared/index.d.ts +85 -0
  405. package/dist/vendor/node-shared/index.js +70 -0
  406. package/dist/vendor/node-shared/internal/nodeChildProcessSpawner.d.ts +4 -0
  407. package/dist/vendor/node-shared/internal/nodeChildProcessSpawner.js +7 -0
  408. package/dist/vendor/node-shared/internal/utils.d.ts +2 -0
  409. package/dist/vendor/node-shared/internal/utils.js +7 -0
  410. package/dist/vendor/platform-bun.d.ts +130 -0
  411. package/dist/vendor/platform-bun.js +121 -0
  412. package/dist/vendor/platform-node-shared.d.ts +85 -0
  413. package/dist/vendor/platform-node-shared.js +70 -0
  414. package/dist/vendor/platform-node.d.ts +140 -0
  415. package/dist/vendor/platform-node.js +130 -0
  416. package/docs/README.md +135 -0
  417. package/docs/api.md +264 -0
  418. package/docs/concepts/host-surface.md +152 -0
  419. package/docs/concepts/runtime-parity.md +80 -0
  420. package/docs/guides/bind-a-repository-root.md +109 -0
  421. package/docs/guides/configure-the-filesystem-helper.md +113 -0
  422. package/docs/guides/contain-child-processes.md +178 -0
  423. package/docs/installation.md +131 -0
  424. package/docs/quickstart.md +163 -0
  425. package/docs/troubleshooting.md +163 -0
  426. package/package.json +146 -3
  427. package/src/BunFileSystem.ts +47 -0
  428. package/src/BunHost.ts +345 -0
  429. package/src/index.ts +27 -0
@@ -0,0 +1,246 @@
1
+ /**
2
+ * Node UDP adapter for `effect/socket/DatagramSocket`, built on `node:dgram`.
3
+ *
4
+ * `make` opens a new `dgram.Socket` for each reader acquisition, `fromSocket`
5
+ * adopts a socket the caller creates, and `layer` provides the
6
+ * `DatagramSocket` service.
7
+ *
8
+ * The reader owns the native socket, so a send-only client must still acquire
9
+ * a reader, or its writes wait forever. Every write waits for Node's send
10
+ * callback, so send errors fail the write that caused them.
11
+ *
12
+ * `writeAll` fails with the first send error. Which of the other datagrams
13
+ * went out is unspecified and nothing is resent; the error carries the failed
14
+ * datagram's `address`.
15
+ *
16
+ * **Example** (Ingest server)
17
+ *
18
+ * ```ts
19
+ * import { NodeDatagramSocket } from "@effect/platform-node-shared"
20
+ * import { Effect } from "effect"
21
+ * import { DatagramSocket } from "effect/socket"
22
+ *
23
+ * const ingest = Effect.gen(function*() {
24
+ * const socket = yield* DatagramSocket.DatagramSocket
25
+ * const reader = yield* socket.reader
26
+ * while (true) {
27
+ * const datagrams = yield* reader.pull
28
+ * yield* Effect.log(`received ${datagrams.length}, dropped ${reader.dropped()}`)
29
+ * }
30
+ * }).pipe(
31
+ * Effect.scoped,
32
+ * Effect.provide(NodeDatagramSocket.layer({
33
+ * bind: { port: 9000 },
34
+ * receiveBuffer: { capacity: 4096, strategy: "sliding" }
35
+ * }))
36
+ * )
37
+ * ```
38
+ *
39
+ * **Example** (Echo server)
40
+ *
41
+ * ```ts
42
+ * import { NodeDatagramSocket } from "@effect/platform-node-shared"
43
+ * import { Effect } from "effect"
44
+ *
45
+ * const echo = Effect.gen(function*() {
46
+ * const socket = yield* NodeDatagramSocket.make({ bind: { port: 9000 } })
47
+ * const reader = yield* socket.reader
48
+ * const writer = yield* socket.writer
49
+ * while (true) {
50
+ * for (const received of yield* reader.pull) {
51
+ * yield* writer.write({ payload: received.payload, address: received })
52
+ * }
53
+ * }
54
+ * }).pipe(Effect.scoped)
55
+ * ```
56
+ *
57
+ * **Example** (Send-only client with a connected socket)
58
+ *
59
+ * ```ts
60
+ * import { NodeDatagramSocket } from "@effect/platform-node-shared"
61
+ * import { Effect } from "effect"
62
+ *
63
+ * const send = (payload: string) =>
64
+ * Effect.gen(function*() {
65
+ * const socket = yield* NodeDatagramSocket.make({
66
+ * connect: { address: "localhost", port: 9000 }
67
+ * })
68
+ * // Required even for send-only clients.
69
+ * yield* socket.reader
70
+ * const writer = yield* socket.writer
71
+ * yield* writer.write({ payload })
72
+ * }).pipe(Effect.scoped)
73
+ * ```
74
+ *
75
+ * **Example** (Multicast receiver and sender)
76
+ *
77
+ * ```ts
78
+ * import { NodeDatagramSocket } from "@effect/platform-node-shared"
79
+ * import { Effect } from "effect"
80
+ * import { NetAddress } from "effect/net"
81
+ *
82
+ * const group = NetAddress.ipFromStringUnsafe("239.255.0.1")
83
+ *
84
+ * const receive = Effect.gen(function*() {
85
+ * if (!NetAddress.isMulticast(group) || !NetAddress.isIpv4Address(group)) return
86
+ * const socket = yield* NodeDatagramSocket.make({
87
+ * bind: { address: "0.0.0.0", port: 5000 },
88
+ * reuseAddress: true
89
+ * })
90
+ * const reader = yield* socket.reader
91
+ * yield* reader.joinMulticast({ group, interface: NetAddress.ipv4Loopback })
92
+ * return yield* reader.pull
93
+ * }).pipe(Effect.scoped)
94
+ *
95
+ * const announce = Effect.gen(function*() {
96
+ * const socket = yield* NodeDatagramSocket.make({
97
+ * peer: { address: group, port: 5000 },
98
+ * // Egress interface, independent of the join's ingress interface.
99
+ * multicast: { interface: NetAddress.ipv4Loopback, ttl: 1, loopback: true }
100
+ * })
101
+ * yield* socket.reader
102
+ * const writer = yield* socket.writer
103
+ * yield* writer.write({ payload: "hello" })
104
+ * }).pipe(Effect.scoped)
105
+ * ```
106
+ *
107
+ * @stability experimental
108
+ * @since 4.0.0
109
+ */
110
+ import * as Effect from "effect/Effect";
111
+ import * as Layer from "effect/Layer";
112
+ import * as NetAddress from "effect/net/NetAddress";
113
+ import type * as Scope from "effect/Scope";
114
+ import * as DatagramSocket from "effect/socket/DatagramSocket";
115
+ import * as Dgram from "node:dgram";
116
+ /**
117
+ * An open-time endpoint. Hostnames resolve once per reader acquisition via
118
+ * `node:dns.lookup`.
119
+ * An `InetAddress` can be passed directly.
120
+ *
121
+ * @stability experimental
122
+ * @category models
123
+ * @since 4.0.0
124
+ */
125
+ export interface Endpoint {
126
+ readonly address: string | NetAddress.IpAddress;
127
+ readonly port: number;
128
+ }
129
+ /**
130
+ * The local address and port to bind. Defaults to `0.0.0.0` (or `::` for
131
+ * `family: "ipv6"`) and an ephemeral port.
132
+ *
133
+ * @stability experimental
134
+ * @category models
135
+ * @since 4.0.0
136
+ */
137
+ export interface BindOptions {
138
+ readonly address?: string | NetAddress.IpAddress | undefined;
139
+ readonly port?: number | undefined;
140
+ }
141
+ /**
142
+ * Options for `make` and `layer`.
143
+ *
144
+ * **Details**
145
+ *
146
+ * `peer` is a default destination and doesn't filter senders. `connect` calls
147
+ * `connect(2)` after binding, so the kernel filters senders and ICMP errors
148
+ * reach `onError`. The two can't be combined.
149
+ *
150
+ * Family selection, in order: explicit `family`, a `bind` IP literal, the
151
+ * `peer` or `connect` address, a `bind` hostname, then `"ipv4"`. Hostname
152
+ * lookups use the family selected so far, or prefer IPv4 if none is set.
153
+ *
154
+ * `reuseAddress` means `SO_REUSEADDR` on Linux and `SO_REUSEPORT` on BSD and
155
+ * macOS. `kernelReceiveBufferSize` and `kernelSendBufferSize` are in bytes;
156
+ * Linux doubles the value and caps it at `rmem_max` / `wmem_max`.
157
+ *
158
+ * `multicast.interface` is the egress interface for datagrams sent to a group,
159
+ * which is a different socket option from the ingress `interface` of
160
+ * `Reader.joinMulticast`.
161
+ *
162
+ * @stability experimental
163
+ * @category models
164
+ * @since 4.0.0
165
+ */
166
+ export type Options = {
167
+ readonly bind?: BindOptions | undefined;
168
+ readonly family?: "ipv4" | "ipv6" | undefined;
169
+ readonly reuseAddress?: boolean | undefined;
170
+ readonly reusePort?: boolean | undefined;
171
+ readonly ipv6Only?: boolean | undefined;
172
+ readonly kernelReceiveBufferSize?: number | undefined;
173
+ readonly kernelSendBufferSize?: number | undefined;
174
+ readonly broadcast?: boolean | undefined;
175
+ readonly ttl?: number | undefined;
176
+ readonly multicast?: {
177
+ readonly interface?: NetAddress.MulticastInterface | undefined;
178
+ readonly loopback?: boolean | undefined;
179
+ readonly ttl?: number | undefined;
180
+ } | undefined;
181
+ readonly receiveBuffer?: DatagramSocket.ReceiveBufferOptions | undefined;
182
+ readonly onError?: ((error: DatagramSocket.DatagramSocketError) => void) | undefined;
183
+ } & ({
184
+ readonly peer?: Endpoint | undefined;
185
+ readonly connect?: undefined;
186
+ } | {
187
+ readonly connect: Endpoint;
188
+ readonly peer?: undefined;
189
+ });
190
+ /**
191
+ * Options for `fromSocket`. The caller configures the adopted socket, so only
192
+ * the options that live in JavaScript apply.
193
+ *
194
+ * @stability experimental
195
+ * @category models
196
+ * @since 4.0.0
197
+ */
198
+ export interface FromSocketOptions {
199
+ readonly peer?: Endpoint | undefined;
200
+ readonly receiveBuffer?: DatagramSocket.ReceiveBufferOptions | undefined;
201
+ readonly onError?: ((error: DatagramSocket.DatagramSocketError) => void) | undefined;
202
+ }
203
+ /**
204
+ * Creates a `DatagramSocket` that opens and binds a new `dgram.Socket` for
205
+ * each reader acquisition.
206
+ *
207
+ * **Details**
208
+ *
209
+ * Creating the socket never fails. Binding, applying options and resolving
210
+ * names happen when a reader is acquired, and fail that acquisition with a
211
+ * `DatagramSocketError`. Hostnames in `bind`, `peer` and `connect` are
212
+ * resolved once per acquisition, so the native socket only sees IP literals
213
+ * and no send waits for DNS.
214
+ *
215
+ * Invalid `receiveBuffer.capacity` values cause a defect; use a positive
216
+ * safe integer.
217
+ *
218
+ * @stability experimental
219
+ * @category constructors
220
+ * @since 4.0.0
221
+ */
222
+ export declare const make: (options?: Options) => Effect.Effect<DatagramSocket.DatagramSocket>;
223
+ /**
224
+ * Adopts a `dgram.Socket`.
225
+ *
226
+ * **Details**
227
+ *
228
+ * `acquire` runs once per reader acquisition, inside the reader's scope, and
229
+ * the adapter closes the socket when that scope ends. The socket must be bound
230
+ * by the time `acquire` completes. Whether it is connected is checked once at
231
+ * open.
232
+ *
233
+ * @stability experimental
234
+ * @category constructors
235
+ * @since 4.0.0
236
+ */
237
+ export declare const fromSocket: <R>(acquire: Effect.Effect<Dgram.Socket, DatagramSocket.DatagramSocketError, R>, options?: FromSocketOptions) => Effect.Effect<DatagramSocket.DatagramSocket, never, Exclude<R, Scope.Scope>>;
238
+ /**
239
+ * Provides a `DatagramSocket` built with `make`.
240
+ *
241
+ * @stability experimental
242
+ * @category layers
243
+ * @since 4.0.0
244
+ */
245
+ export declare const layer: (options?: Options) => Layer.Layer<DatagramSocket.DatagramSocket>;
246
+ //# sourceMappingURL=NodeDatagramSocket.d.ts.map
@@ -0,0 +1,11 @@
1
+ import {
2
+ fromSocket,
3
+ layer,
4
+ make
5
+ } from "../chunk-TCKM3JXD.js";
6
+ import "../chunk-MLKGABMK.js";
7
+ export {
8
+ fromSocket,
9
+ layer,
10
+ make
11
+ };
@@ -0,0 +1,221 @@
1
+ /**
2
+ * Node.js implementation of Effect's `Dns` service.
3
+ *
4
+ * Address lookups use the operating system resolver through `dns.lookup`,
5
+ * including the hosts file. Record queries and reverse lookups share one
6
+ * `dns.Resolver`. Interruption discards a query's result but cannot cancel
7
+ * that query; closing the scope cancels all pending queries.
8
+ *
9
+ * Unrepresentable records, such as invalid `Host.DomainName` values, are
10
+ * skipped. If every record is skipped, the query fails with `InvalidResponse`.
11
+ * `make` decodes Node.js's Latin-1 TXT and CAA strings as UTF-8. TLSA queries
12
+ * need Node.js 22.15 or 23.9 and later, and fail with `Unsupported` on runtimes
13
+ * without `resolveTlsa`. Other runtimes reuse `lookup`, `resolver`, and the
14
+ * conversion helpers to build their services.
15
+ *
16
+ * @stability experimental
17
+ * @since 4.0.0
18
+ */
19
+ import * as Arr from "effect/Array";
20
+ import * as Config from "effect/Config";
21
+ import * as Duration from "effect/Duration";
22
+ import * as Effect from "effect/Effect";
23
+ import * as Layer from "effect/Layer";
24
+ import * as Dns from "effect/net/Dns";
25
+ import * as Host from "effect/net/Host";
26
+ import * as NetAddress from "effect/net/NetAddress";
27
+ import * as Result from "effect/Result";
28
+ /**
29
+ * Options for the Node.js `Dns` service and `resolver`.
30
+ *
31
+ * **Details**
32
+ *
33
+ * `nameServers` replaces the system name servers, which are converted like
34
+ * `Dns.nameServerFromInput`, and an empty list keeps the system name servers.
35
+ * `timeout` is the time allowed for each attempt and `tries` the number of
36
+ * attempts per name server. Address lookups always use the operating system
37
+ * resolver and are not affected.
38
+ *
39
+ * `timeout` is rounded up to whole milliseconds and `tries` down to a whole
40
+ * number, and both are clamped to 1 through 2^31 - 1, so `Duration.infinity`
41
+ * uses the longest timeout the resolver supports.
42
+ *
43
+ * **Gotchas**
44
+ *
45
+ * Invalid name servers fail with a `NetAddress.NetAddressError` when the
46
+ * service is created, and so do IPv6 name servers with a scope ID, such as
47
+ * link-local addresses, because the resolver drops the scope.
48
+ *
49
+ * @stability experimental
50
+ * @category models
51
+ * @since 4.0.0
52
+ */
53
+ export interface Options {
54
+ readonly nameServers?: ReadonlyArray<NetAddress.IpAddressInput | NetAddress.InetAddressInput> | undefined;
55
+ readonly timeout?: Duration.Input | undefined;
56
+ readonly tries?: number | undefined;
57
+ }
58
+ /**
59
+ * Converts a failure of `node:dns` or of Bun's DNS functions to a
60
+ * `Dns.DnsError`, choosing the reason from the error's `code`.
61
+ *
62
+ * **Details**
63
+ *
64
+ * Bun prefixes c-ares codes with `DNS_`, such as `DNS_ENOTFOUND`; the prefix is
65
+ * ignored. Errors without a known code get the reason `Unknown`.
66
+ *
67
+ * @stability experimental
68
+ * @category converting
69
+ * @since 4.0.0
70
+ */
71
+ export declare const dnsErrorFromCause: (cause: unknown, method: Dns.DnsError["method"], hostname: string, recordType?: Dns.RecordType) => Dns.DnsError;
72
+ /**
73
+ * Converts a name returned by a resolver to a fully qualified
74
+ * `Host.DomainName`, throwing when it is not a valid domain name.
75
+ *
76
+ * @stability experimental
77
+ * @category converting
78
+ * @since 4.0.0
79
+ */
80
+ export declare const domainNameFromResolverUnsafe: (name: string) => Host.DomainName;
81
+ /**
82
+ * Converts a name returned by a resolver to fully qualified text, for names
83
+ * that need not be host names, such as PTR targets and SOA mailboxes.
84
+ *
85
+ * **Details**
86
+ *
87
+ * Resolvers write bytes as `\DDD` escapes, c-ares in decimal (`radix` 10) and
88
+ * `Deno.resolveDns` in octal (`radix` 8), and escape special characters with
89
+ * a backslash, such as `\.` for a dot inside a label or `\(` for a
90
+ * parenthesis. Decoding the bytes as UTF-8 and removing the escapes gives the
91
+ * text of the name, keeping only the `\.` and `\\` escapes.
92
+ *
93
+ * @stability experimental
94
+ * @category converting
95
+ * @since 4.0.0
96
+ */
97
+ export declare const nameTextFromResolver: (name: string, radix?: 8 | 10) => string;
98
+ /**
99
+ * Converts a number of seconds that a resolver reports as a signed 32-bit
100
+ * integer, such as the SOA refresh, retry, and expire intervals, to a
101
+ * `Duration`.
102
+ *
103
+ * @stability experimental
104
+ * @category converting
105
+ * @since 4.0.0
106
+ */
107
+ export declare const secondsFromInt32: (value: number) => Duration.Duration;
108
+ /**
109
+ * Decodes a string that holds one byte per character as UTF-8.
110
+ *
111
+ * **Details**
112
+ *
113
+ * Node.js and `Deno.resolveDns` decode each byte of TXT and CAA character
114
+ * strings as one Latin-1 character; decoding the bytes as UTF-8 matches other
115
+ * runtimes. Strings with only ASCII characters are returned unchanged.
116
+ *
117
+ * @stability experimental
118
+ * @category converting
119
+ * @since 4.0.0
120
+ */
121
+ export declare const utf8FromLatin1: (value: string) => string;
122
+ /**
123
+ * Converts the entries of a resolver's answer to a query for `name` to records
124
+ * of a record type, skipping entries whose data cannot be represented, such as
125
+ * names that are not valid `Host.DomainName` values.
126
+ *
127
+ * **Details**
128
+ *
129
+ * When the answer has entries but every one is skipped, the conversion fails
130
+ * with an `InvalidResponse` error whose cause is the first entry's failure,
131
+ * rather than returning no records, which would be reported as `NotFound`.
132
+ *
133
+ * @stability experimental
134
+ * @category converting
135
+ * @since 4.0.0
136
+ */
137
+ export declare const recordsFromResolver: <T extends Dns.RecordType, A>(name: string, type: T, entries: ReadonlyArray<A>, fields: (entry: A) => Dns.RecordFields<T>) => Result.Result<Array<Dns.RecordFor<T>>, Dns.DnsError>;
138
+ /**
139
+ * Converts an IP family to the numeric family used by `dns.lookup`, with `0`
140
+ * for addresses of either family.
141
+ *
142
+ * @stability experimental
143
+ * @category converting
144
+ * @since 4.0.0
145
+ */
146
+ export declare const toFamily: (family: NetAddress.IpFamily | undefined) => 0 | 4 | 6;
147
+ /**
148
+ * Converts the entries returned by an address lookup, such as `dns.lookup`
149
+ * with `all: true`, to IP addresses, keeping their order.
150
+ *
151
+ * **Details**
152
+ *
153
+ * IPv6 zones are dropped, and addresses that cannot be parsed are skipped.
154
+ *
155
+ * @stability experimental
156
+ * @category converting
157
+ * @since 4.0.0
158
+ */
159
+ export declare const addressesFromLookup: (entries: ReadonlyArray<{
160
+ readonly address: string;
161
+ }>) => Array<NetAddress.IpAddress>;
162
+ /**
163
+ * Looks up the addresses of a host name with `dns.lookup`, keeping the order
164
+ * returned by the operating system resolver.
165
+ *
166
+ * @stability experimental
167
+ * @category resolving
168
+ * @since 4.0.0
169
+ */
170
+ export declare const lookup: (host: string, family?: NetAddress.IpFamily | undefined) => Effect.Effect<Array<NetAddress.IpAddress>, Dns.DnsError>;
171
+ /**
172
+ * Creates a function that queries DNS records with the runtime's `node:dns`
173
+ * module.
174
+ *
175
+ * **Details**
176
+ *
177
+ * All queries share one `dns.Resolver`, which is cancelled when the scope
178
+ * closes. Names in records are fully qualified, and TXT and CAA character
179
+ * strings are returned as the runtime decodes them, without the UTF-8
180
+ * correction that `make` applies for Node.js. Records are converted with
181
+ * `recordsFromResolver`.
182
+ *
183
+ * @stability experimental
184
+ * @category constructors
185
+ * @since 4.0.0
186
+ */
187
+ export declare const resolver: (options?: Options | undefined) => Effect.Effect<(name: string, type: Dns.RecordType) => Effect.Effect<Array<Dns.DnsRecord>, Dns.DnsError>, NetAddress.NetAddressError, import("effect/Scope").Scope>;
188
+ /**
189
+ * Creates a Node.js `Dns` service whose resolver lives as long as the scope.
190
+ *
191
+ * @stability experimental
192
+ * @category constructors
193
+ * @since 4.0.0
194
+ */
195
+ export declare const make: (options?: Options | undefined) => Effect.Effect<{
196
+ lookup<F extends NetAddress.IpFamily>(host: Host.DomainNameInput, options: {
197
+ readonly family: F;
198
+ }): Effect.Effect<Arr.NonEmptyReadonlyArray<NetAddress.FamilyAddress<F>>, Dns.DnsError>;
199
+ lookup(host: Host.DomainNameInput, options?: Dns.LookupOptions): Effect.Effect<Arr.NonEmptyReadonlyArray<NetAddress.IpAddress>, Dns.DnsError>;
200
+ resolve<T extends Dns.RecordType>(name: Host.DomainNameInput, type: T): Effect.Effect<Arr.NonEmptyReadonlyArray<Dns.RecordFor<T>>, Dns.DnsError>;
201
+ reverse(address: NetAddress.IpAddressInput): Effect.Effect<Arr.NonEmptyReadonlyArray<Host.DomainName>, Dns.DnsError>;
202
+ }, NetAddress.NetAddressError, import("effect/Scope").Scope>;
203
+ /**
204
+ * Layer that provides the Node.js `Dns` service using the system resolver
205
+ * configuration.
206
+ *
207
+ * @stability experimental
208
+ * @category layers
209
+ * @since 4.0.0
210
+ */
211
+ export declare const layer: Layer.Layer<Dns.Dns>;
212
+ /**
213
+ * Creates a layer that provides the Node.js `Dns` service with options read
214
+ * from configuration.
215
+ *
216
+ * @stability experimental
217
+ * @category layers
218
+ * @since 4.0.0
219
+ */
220
+ export declare const layerConfig: (options: Config.Wrap<Options>) => Layer.Layer<Dns.Dns, Config.ConfigError | NetAddress.NetAddressError>;
221
+ //# sourceMappingURL=NodeDns.d.ts.map
@@ -0,0 +1,31 @@
1
+ import {
2
+ addressesFromLookup,
3
+ dnsErrorFromCause,
4
+ domainNameFromResolverUnsafe,
5
+ layer,
6
+ layerConfig,
7
+ lookup,
8
+ make,
9
+ nameTextFromResolver,
10
+ recordsFromResolver,
11
+ resolver,
12
+ secondsFromInt32,
13
+ toFamily,
14
+ utf8FromLatin1
15
+ } from "../chunk-R2PFJKSP.js";
16
+ import "../chunk-MLKGABMK.js";
17
+ export {
18
+ addressesFromLookup,
19
+ dnsErrorFromCause,
20
+ domainNameFromResolverUnsafe,
21
+ layer,
22
+ layerConfig,
23
+ lookup,
24
+ make,
25
+ nameTextFromResolver,
26
+ recordsFromResolver,
27
+ resolver,
28
+ secondsFromInt32,
29
+ toFamily,
30
+ utf8FromLatin1
31
+ };
@@ -0,0 +1,12 @@
1
+ import * as FileSystem from "effect/FileSystem";
2
+ import * as Layer from "effect/Layer";
3
+ /**
4
+ * Provides the `FileSystem` service backed by Node filesystem APIs, including
5
+ * file operations, directory operations, links, metadata, and file watching.
6
+ *
7
+ * @stability unstable
8
+ * @category layers
9
+ * @since 4.0.0
10
+ */
11
+ export declare const layer: Layer.Layer<FileSystem.FileSystem>;
12
+ //# sourceMappingURL=NodeFileSystem.d.ts.map
@@ -0,0 +1,8 @@
1
+ import {
2
+ layer
3
+ } from "../chunk-7JOAEKDV.js";
4
+ import "../chunk-3SUO3TTE.js";
5
+ import "../chunk-MLKGABMK.js";
6
+ export {
7
+ layer
8
+ };
@@ -0,0 +1,40 @@
1
+ import type * as Platform from "effect/http/HttpPlatform";
2
+ import type { Duplex } from "node:stream";
3
+ /**
4
+ * The compression algorithms supported by the runtime's `node:zlib`. `zstd`
5
+ * requires Node.js 22.15 or newer.
6
+ *
7
+ * @stability unstable
8
+ * @category constants
9
+ * @since 4.0.0
10
+ */
11
+ export declare const algorithms: ReadonlySet<Platform.CompressionAlgorithm>;
12
+ /**
13
+ * Creates a `Compression` that compresses byte-array bodies in one shot with
14
+ * the asynchronous `node:zlib` APIs, setting the exact `Content-Length` of the
15
+ * compressed body. All other bodies are delegated to `fallback`.
16
+ *
17
+ * @stability unstable
18
+ * @category constructors
19
+ * @since 4.0.0
20
+ */
21
+ export declare const make: (fallback: Platform.Compression) => Platform.Compression;
22
+ /**
23
+ * Creates a `node:zlib` compression transform stream that flushes each input
24
+ * chunk, for streaming response bodies.
25
+ *
26
+ * @stability unstable
27
+ * @category constructors
28
+ * @since 4.0.0
29
+ */
30
+ export declare const compressTransform: (algorithm: Platform.CompressionAlgorithm, options?: Platform.CompressionOptions | undefined) => Duplex;
31
+ /**
32
+ * A Web `ReadableStream` version of `compressTransform`, for platforms that
33
+ * stream response bodies as Web streams.
34
+ *
35
+ * @stability unstable
36
+ * @category constructors
37
+ * @since 4.0.0
38
+ */
39
+ export declare const compressTransformWeb: (algorithm: Platform.CompressionAlgorithm, options?: Platform.CompressionOptions | undefined) => (stream: ReadableStream<Uint8Array>) => ReadableStream<Uint8Array>;
40
+ //# sourceMappingURL=NodeHttpCompression.d.ts.map
@@ -0,0 +1,13 @@
1
+ import {
2
+ algorithms,
3
+ compressTransform,
4
+ compressTransformWeb,
5
+ make
6
+ } from "../chunk-PBM2HJOX.js";
7
+ import "../chunk-MLKGABMK.js";
8
+ export {
9
+ algorithms,
10
+ compressTransform,
11
+ compressTransformWeb,
12
+ make
13
+ };
@@ -0,0 +1,30 @@
1
+ import * as Layer from "effect/Layer";
2
+ import { Path } from "effect/Path";
3
+ /**
4
+ * Provides the `Path` service using Node's POSIX path implementation plus
5
+ * file URL conversion helpers.
6
+ *
7
+ * @stability unstable
8
+ * @category layers
9
+ * @since 4.0.0
10
+ */
11
+ export declare const layerPosix: Layer.Layer<Path>;
12
+ /**
13
+ * Provides the `Path` service using Node's Windows path implementation plus
14
+ * file URL conversion helpers.
15
+ *
16
+ * @stability unstable
17
+ * @category layers
18
+ * @since 4.0.0
19
+ */
20
+ export declare const layerWin32: Layer.Layer<Path>;
21
+ /**
22
+ * Provides the default `Path` service using the host platform's Node path
23
+ * implementation plus file URL conversion helpers.
24
+ *
25
+ * @stability unstable
26
+ * @category layers
27
+ * @since 4.0.0
28
+ */
29
+ export declare const layer: Layer.Layer<Path>;
30
+ //# sourceMappingURL=NodePath.d.ts.map
@@ -0,0 +1,11 @@
1
+ import {
2
+ layer,
3
+ layerPosix,
4
+ layerWin32
5
+ } from "../chunk-JTST2Z7N.js";
6
+ import "../chunk-MLKGABMK.js";
7
+ export {
8
+ layer,
9
+ layerPosix,
10
+ layerWin32
11
+ };
@@ -0,0 +1,51 @@
1
+ /**
2
+ * Node-compatible process runner for Effect programs.
3
+ *
4
+ * This module provides the shared `runMain` implementation used by
5
+ * Node-compatible platform packages. It runs one Effect as the main process
6
+ * fiber, interrupts that fiber on `SIGINT` or `SIGTERM`, and delegates final
7
+ * exit-code handling to the configured teardown.
8
+ *
9
+ * @stability unstable
10
+ * @since 4.0.0
11
+ */
12
+ import type { Effect } from "effect/Effect";
13
+ import * as Runtime from "effect/Runtime";
14
+ /**
15
+ * Runs an Effect as the Node process main program, interrupting the fiber on
16
+ * `SIGINT` or `SIGTERM` and invoking the configured teardown to determine the
17
+ * process exit code.
18
+ *
19
+ * @stability unstable
20
+ * @category running
21
+ * @since 4.0.0
22
+ */
23
+ export declare const runMain: {
24
+ /**
25
+ * Runs an Effect as the Node process main program, interrupting the fiber on
26
+ * `SIGINT` or `SIGTERM` and invoking the configured teardown to determine the
27
+ * process exit code.
28
+ *
29
+ * @stability unstable
30
+ * @category running
31
+ * @since 4.0.0
32
+ */
33
+ (options?: {
34
+ readonly disableErrorReporting?: boolean | undefined;
35
+ readonly teardown?: Runtime.Teardown | undefined;
36
+ }): <E, A>(effect: Effect<A, E>) => void;
37
+ /**
38
+ * Runs an Effect as the Node process main program, interrupting the fiber on
39
+ * `SIGINT` or `SIGTERM` and invoking the configured teardown to determine the
40
+ * process exit code.
41
+ *
42
+ * @stability unstable
43
+ * @category running
44
+ * @since 4.0.0
45
+ */
46
+ <E, A>(effect: Effect<A, E>, options?: {
47
+ readonly disableErrorReporting?: boolean | undefined;
48
+ readonly teardown?: Runtime.Teardown | undefined;
49
+ }): void;
50
+ };
51
+ //# sourceMappingURL=NodeRuntime.d.ts.map
@@ -0,0 +1,7 @@
1
+ import {
2
+ runMain
3
+ } from "../chunk-BHV44Z6K.js";
4
+ import "../chunk-MLKGABMK.js";
5
+ export {
6
+ runMain
7
+ };