@effect/platform-bun 4.0.0-beta.8 → 4.0.0-beta.80
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/BunChildProcessSpawner.d.ts +1 -1
- package/dist/BunChildProcessSpawner.js +1 -1
- package/dist/BunClusterHttp.d.ts +44 -7
- package/dist/BunClusterHttp.d.ts.map +1 -1
- package/dist/BunClusterHttp.js +41 -10
- package/dist/BunClusterHttp.js.map +1 -1
- package/dist/BunClusterSocket.d.ts +27 -9
- package/dist/BunClusterSocket.d.ts.map +1 -1
- package/dist/BunClusterSocket.js +27 -9
- package/dist/BunClusterSocket.js.map +1 -1
- package/dist/BunCrypto.d.ts +10 -0
- package/dist/BunCrypto.d.ts.map +1 -0
- package/dist/BunCrypto.js +22 -0
- package/dist/BunCrypto.js.map +1 -0
- package/dist/BunFileSystem.d.ts +4 -2
- package/dist/BunFileSystem.d.ts.map +1 -1
- package/dist/BunFileSystem.js +11 -3
- package/dist/BunFileSystem.js.map +1 -1
- package/dist/BunHttpClient.d.ts +2 -2
- package/dist/BunHttpClient.js +2 -2
- package/dist/BunHttpPlatform.d.ts +4 -2
- package/dist/BunHttpPlatform.d.ts.map +1 -1
- package/dist/BunHttpPlatform.js +5 -3
- package/dist/BunHttpPlatform.js.map +1 -1
- package/dist/BunHttpServer.d.ts +57 -20
- package/dist/BunHttpServer.d.ts.map +1 -1
- package/dist/BunHttpServer.js +63 -36
- package/dist/BunHttpServer.js.map +1 -1
- package/dist/BunHttpServerRequest.d.ts +11 -3
- package/dist/BunHttpServerRequest.d.ts.map +1 -1
- package/dist/BunHttpServerRequest.js +4 -2
- package/dist/BunHttpServerRequest.js.map +1 -1
- package/dist/BunMultipart.d.ts +16 -5
- package/dist/BunMultipart.d.ts.map +1 -1
- package/dist/BunMultipart.js +15 -5
- package/dist/BunMultipart.js.map +1 -1
- package/dist/BunPath.d.ts +12 -6
- package/dist/BunPath.d.ts.map +1 -1
- package/dist/BunPath.js +20 -7
- package/dist/BunPath.js.map +1 -1
- package/dist/BunRedis.d.ts +23 -9
- package/dist/BunRedis.d.ts.map +1 -1
- package/dist/BunRedis.js +26 -12
- package/dist/BunRedis.js.map +1 -1
- package/dist/BunRuntime.d.ts +21 -30
- package/dist/BunRuntime.d.ts.map +1 -1
- package/dist/BunRuntime.js +14 -11
- package/dist/BunRuntime.js.map +1 -1
- package/dist/BunServices.d.ts +19 -5
- package/dist/BunServices.d.ts.map +1 -1
- package/dist/BunServices.js +7 -3
- package/dist/BunServices.js.map +1 -1
- package/dist/BunSink.d.ts +2 -2
- package/dist/BunSink.js +2 -2
- package/dist/BunSocket.d.ts +18 -4
- package/dist/BunSocket.d.ts.map +1 -1
- package/dist/BunSocket.js +10 -3
- package/dist/BunSocket.js.map +1 -1
- package/dist/BunSocketServer.d.ts +2 -2
- package/dist/BunSocketServer.js +2 -2
- package/dist/BunStdio.d.ts +5 -2
- package/dist/BunStdio.d.ts.map +1 -1
- package/dist/BunStdio.js +13 -3
- package/dist/BunStdio.js.map +1 -1
- package/dist/BunStream.d.ts +5 -4
- package/dist/BunStream.d.ts.map +1 -1
- package/dist/BunStream.js +14 -5
- package/dist/BunStream.js.map +1 -1
- package/dist/BunTerminal.d.ts +8 -2
- package/dist/BunTerminal.d.ts.map +1 -1
- package/dist/BunTerminal.js +15 -3
- package/dist/BunTerminal.js.map +1 -1
- package/dist/BunWorker.d.ts +9 -2
- package/dist/BunWorker.d.ts.map +1 -1
- package/dist/BunWorker.js +20 -4
- package/dist/BunWorker.js.map +1 -1
- package/dist/BunWorkerRunner.d.ts +5 -1
- package/dist/BunWorkerRunner.d.ts.map +1 -1
- package/dist/BunWorkerRunner.js +17 -5
- package/dist/BunWorkerRunner.js.map +1 -1
- package/dist/index.d.ts +25 -23
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +25 -23
- package/dist/index.js.map +1 -1
- package/package.json +5 -5
- package/src/BunChildProcessSpawner.ts +1 -1
- package/src/BunClusterHttp.ts +49 -11
- package/src/BunClusterSocket.ts +27 -9
- package/src/BunCrypto.ts +24 -0
- package/src/BunFileSystem.ts +11 -3
- package/src/BunHttpClient.ts +2 -2
- package/src/BunHttpPlatform.ts +14 -4
- package/src/BunHttpServer.ts +108 -57
- package/src/BunHttpServerRequest.ts +11 -3
- package/src/BunMultipart.ts +24 -6
- package/src/BunPath.ts +20 -7
- package/src/BunRedis.ts +28 -14
- package/src/BunRuntime.ts +28 -31
- package/src/BunServices.ts +21 -5
- package/src/BunSink.ts +2 -2
- package/src/BunSocket.ts +18 -4
- package/src/BunSocketServer.ts +2 -2
- package/src/BunStdio.ts +13 -3
- package/src/BunStream.ts +14 -5
- package/src/BunTerminal.ts +15 -3
- package/src/BunWorker.ts +20 -4
- package/src/BunWorkerRunner.ts +17 -5
- package/src/index.ts +26 -23
package/dist/BunPath.js
CHANGED
|
@@ -1,20 +1,33 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @
|
|
2
|
+
* Bun-backed layers for Effect's {@link Path} service.
|
|
3
|
+
*
|
|
4
|
+
* This module provides the `Path` service for Bun programs by reusing the
|
|
5
|
+
* shared Node-compatible path implementation. Provide one of these layers when
|
|
6
|
+
* Bun code should receive path operations from the Effect environment instead
|
|
7
|
+
* of importing runtime path helpers directly.
|
|
8
|
+
*
|
|
9
|
+
* @since 4.0.0
|
|
3
10
|
*/
|
|
4
11
|
import * as NodePath from "@effect/platform-node-shared/NodePath";
|
|
5
12
|
/**
|
|
6
|
-
*
|
|
7
|
-
*
|
|
13
|
+
* Layer that provides the default `Path` service for Bun using the shared Node path implementation.
|
|
14
|
+
*
|
|
15
|
+
* @category layers
|
|
16
|
+
* @since 4.0.0
|
|
8
17
|
*/
|
|
9
18
|
export const layer = NodePath.layer;
|
|
10
19
|
/**
|
|
11
|
-
*
|
|
12
|
-
*
|
|
20
|
+
* Layer that provides the POSIX `Path` service for Bun using the shared Node path implementation.
|
|
21
|
+
*
|
|
22
|
+
* @category layers
|
|
23
|
+
* @since 4.0.0
|
|
13
24
|
*/
|
|
14
25
|
export const layerPosix = NodePath.layerPosix;
|
|
15
26
|
/**
|
|
16
|
-
*
|
|
17
|
-
*
|
|
27
|
+
* Layer that provides the Win32 `Path` service for Bun using the shared Node path implementation.
|
|
28
|
+
*
|
|
29
|
+
* @category layers
|
|
30
|
+
* @since 4.0.0
|
|
18
31
|
*/
|
|
19
32
|
export const layerWin32 = NodePath.layerWin32;
|
|
20
33
|
//# sourceMappingURL=BunPath.js.map
|
package/dist/BunPath.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BunPath.js","names":["NodePath","layer","layerPosix","layerWin32"],"sources":["../src/BunPath.ts"],"sourcesContent":[null],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"BunPath.js","names":["NodePath","layer","layerPosix","layerWin32"],"sources":["../src/BunPath.ts"],"sourcesContent":[null],"mappings":"AAAA;;;;;;;;;;AAUA,OAAO,KAAKA,QAAQ,MAAM,uCAAuC;AAIjE;;;;;;AAMA,OAAO,MAAMC,KAAK,GAAsBD,QAAQ,CAACC,KAAK;AAEtD;;;;;;AAMA,OAAO,MAAMC,UAAU,GAAsBF,QAAQ,CAACE,UAAU;AAEhE;;;;;;AAMA,OAAO,MAAMC,UAAU,GAAsBH,QAAQ,CAACG,UAAU","ignoreList":[]}
|
package/dist/BunRedis.d.ts
CHANGED
|
@@ -1,32 +1,46 @@
|
|
|
1
1
|
/**
|
|
2
|
-
*
|
|
2
|
+
* Bun Redis integration backed by Bun's built-in `RedisClient`.
|
|
3
|
+
*
|
|
4
|
+
* This module creates scoped Bun `RedisClient` connections and exposes them as
|
|
5
|
+
* both the portable `Redis` service and the Bun-specific `BunRedis` service for
|
|
6
|
+
* direct access to the raw client. The `layer` helper accepts Redis options
|
|
7
|
+
* directly, while `layerConfig` reads them from Effect config. Both close the
|
|
8
|
+
* underlying client when the layer scope finalizes.
|
|
9
|
+
*
|
|
10
|
+
* @since 4.0.0
|
|
3
11
|
*/
|
|
4
12
|
import { RedisClient, type RedisOptions } from "bun";
|
|
5
13
|
import * as Config from "effect/Config";
|
|
14
|
+
import * as Context from "effect/Context";
|
|
6
15
|
import * as Effect from "effect/Effect";
|
|
7
16
|
import * as Layer from "effect/Layer";
|
|
8
|
-
import * as ServiceMap from "effect/ServiceMap";
|
|
9
17
|
import * as Redis from "effect/unstable/persistence/Redis";
|
|
10
|
-
declare const BunRedis_base:
|
|
18
|
+
declare const BunRedis_base: Context.ServiceClass<BunRedis, "@effect/platform-bun/BunRedis", {
|
|
11
19
|
readonly client: RedisClient;
|
|
12
20
|
readonly use: <A>(f: (client: RedisClient) => Promise<A>) => Effect.Effect<A, Redis.RedisError>;
|
|
13
21
|
}>;
|
|
14
22
|
/**
|
|
15
|
-
*
|
|
16
|
-
*
|
|
23
|
+
* Service tag for Bun Redis integration, exposing the raw `RedisClient` and a `use` helper that maps client promise failures to `RedisError`.
|
|
24
|
+
*
|
|
25
|
+
* @category services
|
|
26
|
+
* @since 4.0.0
|
|
17
27
|
*/
|
|
18
28
|
export declare class BunRedis extends BunRedis_base {
|
|
19
29
|
}
|
|
20
30
|
/**
|
|
21
|
-
*
|
|
22
|
-
*
|
|
31
|
+
* Creates scoped Bun Redis layers for `Redis.Redis` and `BunRedis`, closing the underlying client when the scope finalizes.
|
|
32
|
+
*
|
|
33
|
+
* @category layers
|
|
34
|
+
* @since 4.0.0
|
|
23
35
|
*/
|
|
24
36
|
export declare const layer: (options?: ({
|
|
25
37
|
readonly url?: string;
|
|
26
38
|
} & RedisOptions) | undefined) => Layer.Layer<Redis.Redis | BunRedis>;
|
|
27
39
|
/**
|
|
28
|
-
*
|
|
29
|
-
*
|
|
40
|
+
* Creates scoped Bun Redis layers from configurable Redis options, closing the underlying client when the scope finalizes.
|
|
41
|
+
*
|
|
42
|
+
* @category layers
|
|
43
|
+
* @since 4.0.0
|
|
30
44
|
*/
|
|
31
45
|
export declare const layerConfig: (options: Config.Wrap<{
|
|
32
46
|
readonly url?: string;
|
package/dist/BunRedis.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BunRedis.d.ts","sourceRoot":"","sources":["../src/BunRedis.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"BunRedis.d.ts","sourceRoot":"","sources":["../src/BunRedis.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AACH,OAAO,EAAE,WAAW,EAAE,KAAK,YAAY,EAAE,MAAM,KAAK,CAAA;AACpD,OAAO,KAAK,MAAM,MAAM,eAAe,CAAA;AACvC,OAAO,KAAK,OAAO,MAAM,gBAAgB,CAAA;AACzC,OAAO,KAAK,MAAM,MAAM,eAAe,CAAA;AAEvC,OAAO,KAAK,KAAK,MAAM,cAAc,CAAA;AAErC,OAAO,KAAK,KAAK,MAAM,mCAAmC,CAAA;;qBASvC,WAAW;kBACd,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,MAAM,EAAE,WAAW,KAAK,OAAO,CAAC,CAAC,CAAC,KAAK,MAAM,CAAC,MAAM,CAAC,CAAC,EAAE,KAAK,CAAC,UAAU,CAAC;;AARjG;;;;;GAKG;AACH,qBAAa,QAAS,SAAQ,aAGO;CAAG;AAmCxC;;;;;GAKG;AACH,eAAO,MAAM,KAAK,GAChB,UAAU,CAAC;IAAE,QAAQ,CAAC,GAAG,CAAC,EAAE,MAAM,CAAA;CAAE,GAAG,YAAY,CAAC,GAAG,SAAS,KAC/D,KAAK,CAAC,KAAK,CAAC,KAAK,CAAC,KAAK,GAAG,QAAQ,CAAuC,CAAA;AAE5E;;;;;GAKG;AACH,eAAO,MAAM,WAAW,GACtB,SAAS,MAAM,CAAC,IAAI,CAAC;IAAE,QAAQ,CAAC,GAAG,CAAC,EAAE,MAAM,CAAA;CAAE,GAAG,YAAY,CAAC,KAC7D,KAAK,CAAC,KAAK,CAAC,KAAK,CAAC,KAAK,GAAG,QAAQ,EAAE,MAAM,CAAC,WAAW,CAKtD,CAAA"}
|
package/dist/BunRedis.js
CHANGED
|
@@ -1,19 +1,29 @@
|
|
|
1
1
|
/**
|
|
2
|
-
*
|
|
2
|
+
* Bun Redis integration backed by Bun's built-in `RedisClient`.
|
|
3
|
+
*
|
|
4
|
+
* This module creates scoped Bun `RedisClient` connections and exposes them as
|
|
5
|
+
* both the portable `Redis` service and the Bun-specific `BunRedis` service for
|
|
6
|
+
* direct access to the raw client. The `layer` helper accepts Redis options
|
|
7
|
+
* directly, while `layerConfig` reads them from Effect config. Both close the
|
|
8
|
+
* underlying client when the layer scope finalizes.
|
|
9
|
+
*
|
|
10
|
+
* @since 4.0.0
|
|
3
11
|
*/
|
|
4
12
|
import { RedisClient } from "bun";
|
|
5
13
|
import * as Config from "effect/Config";
|
|
14
|
+
import * as Context from "effect/Context";
|
|
6
15
|
import * as Effect from "effect/Effect";
|
|
7
16
|
import * as Fn from "effect/Function";
|
|
8
17
|
import * as Layer from "effect/Layer";
|
|
9
18
|
import * as Scope from "effect/Scope";
|
|
10
|
-
import * as ServiceMap from "effect/ServiceMap";
|
|
11
19
|
import * as Redis from "effect/unstable/persistence/Redis";
|
|
12
20
|
/**
|
|
13
|
-
*
|
|
14
|
-
*
|
|
21
|
+
* Service tag for Bun Redis integration, exposing the raw `RedisClient` and a `use` helper that maps client promise failures to `RedisError`.
|
|
22
|
+
*
|
|
23
|
+
* @category services
|
|
24
|
+
* @since 4.0.0
|
|
15
25
|
*/
|
|
16
|
-
export class BunRedis extends /*#__PURE__*/
|
|
26
|
+
export class BunRedis extends /*#__PURE__*/Context.Service()("@effect/platform-bun/BunRedis") {}
|
|
17
27
|
const make = /*#__PURE__*/Effect.fnUntraced(function* (options) {
|
|
18
28
|
const scope = yield* Effect.scope;
|
|
19
29
|
yield* Scope.addFinalizer(scope, Effect.sync(() => client.close()));
|
|
@@ -36,16 +46,20 @@ const make = /*#__PURE__*/Effect.fnUntraced(function* (options) {
|
|
|
36
46
|
client,
|
|
37
47
|
use
|
|
38
48
|
});
|
|
39
|
-
return
|
|
49
|
+
return Context.make(BunRedis, bunRedis).pipe(Context.add(Redis.Redis, redis));
|
|
40
50
|
});
|
|
41
51
|
/**
|
|
42
|
-
*
|
|
43
|
-
*
|
|
52
|
+
* Creates scoped Bun Redis layers for `Redis.Redis` and `BunRedis`, closing the underlying client when the scope finalizes.
|
|
53
|
+
*
|
|
54
|
+
* @category layers
|
|
55
|
+
* @since 4.0.0
|
|
44
56
|
*/
|
|
45
|
-
export const layer = options => Layer.
|
|
57
|
+
export const layer = options => Layer.effectContext(make(options));
|
|
46
58
|
/**
|
|
47
|
-
*
|
|
48
|
-
*
|
|
59
|
+
* Creates scoped Bun Redis layers from configurable Redis options, closing the underlying client when the scope finalizes.
|
|
60
|
+
*
|
|
61
|
+
* @category layers
|
|
62
|
+
* @since 4.0.0
|
|
49
63
|
*/
|
|
50
|
-
export const layerConfig = options => Layer.
|
|
64
|
+
export const layerConfig = options => Layer.effectContext(Config.unwrap(options).pipe(Effect.flatMap(make)));
|
|
51
65
|
//# sourceMappingURL=BunRedis.js.map
|
package/dist/BunRedis.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BunRedis.js","names":["RedisClient","Config","Effect","Fn","Layer","Scope","
|
|
1
|
+
{"version":3,"file":"BunRedis.js","names":["RedisClient","Config","Context","Effect","Fn","Layer","Scope","Redis","BunRedis","Service","make","fnUntraced","options","scope","addFinalizer","sync","client","close","url","use","f","tryPromise","try","catch","cause","RedisError","redis","send","command","args","bunRedis","identity","pipe","add","layer","effectContext","layerConfig","unwrap","flatMap"],"sources":["../src/BunRedis.ts"],"sourcesContent":[null],"mappings":"AAAA;;;;;;;;;;;AAWA,SAASA,WAAW,QAA2B,KAAK;AACpD,OAAO,KAAKC,MAAM,MAAM,eAAe;AACvC,OAAO,KAAKC,OAAO,MAAM,gBAAgB;AACzC,OAAO,KAAKC,MAAM,MAAM,eAAe;AACvC,OAAO,KAAKC,EAAE,MAAM,iBAAiB;AACrC,OAAO,KAAKC,KAAK,MAAM,cAAc;AACrC,OAAO,KAAKC,KAAK,MAAM,cAAc;AACrC,OAAO,KAAKC,KAAK,MAAM,mCAAmC;AAE1D;;;;;;AAMA,OAAM,MAAOC,QAAS,sBAAQN,OAAO,CAACO,OAAO,EAGzC,CAAC,+BAA+B,CAAC;AAErC,MAAMC,IAAI,gBAAGP,MAAM,CAACQ,UAAU,CAAC,WAC7BC,OAEgB;EAEhB,MAAMC,KAAK,GAAG,OAAOV,MAAM,CAACU,KAAK;EACjC,OAAOP,KAAK,CAACQ,YAAY,CAACD,KAAK,EAAEV,MAAM,CAACY,IAAI,CAAC,MAAMC,MAAM,CAACC,KAAK,EAAE,CAAC,CAAC;EACnE,MAAMD,MAAM,GAAG,IAAIhB,WAAW,CAACY,OAAO,EAAEM,GAAG,EAAEN,OAAO,CAAC;EAErD,MAAMO,GAAG,GAAOC,CAAsC,IACpDjB,MAAM,CAACkB,UAAU,CAAC;IAChBC,GAAG,EAAEA,CAAA,KAAMF,CAAC,CAACJ,MAAM,CAAC;IACpBO,KAAK,EAAGC,KAAK,IAAK,IAAIjB,KAAK,CAACkB,UAAU,CAAC;MAAED;IAAK,CAAE;GACjD,CAAC;EAEJ,MAAME,KAAK,GAAG,OAAOnB,KAAK,CAACG,IAAI,CAAC;IAC9BiB,IAAI,EAAEA,CAAcC,OAAe,EAAE,GAAGC,IAA2B,KACjE1B,MAAM,CAACkB,UAAU,CAAC;MAChBC,GAAG,EAAEA,CAAA,KAAMN,MAAM,CAACW,IAAI,CAACC,OAAO,EAAEC,IAAqB,CAAe;MACpEN,KAAK,EAAGC,KAAK,IAAK,IAAIjB,KAAK,CAACkB,UAAU,CAAC;QAAED;MAAK,CAAE;KACjD;GACJ,CAAC;EAEF,MAAMM,QAAQ,GAAG1B,EAAE,CAAC2B,QAAQ,CAAsB;IAChDf,MAAM;IACNG;GACD,CAAC;EAEF,OAAOjB,OAAO,CAACQ,IAAI,CAACF,QAAQ,EAAEsB,QAAQ,CAAC,CAACE,IAAI,CAC1C9B,OAAO,CAAC+B,GAAG,CAAC1B,KAAK,CAACA,KAAK,EAAEmB,KAAK,CAAC,CAChC;AACH,CAAC,CAAC;AAEF;;;;;;AAMA,OAAO,MAAMQ,KAAK,GAChBtB,OAAgE,IACxBP,KAAK,CAAC8B,aAAa,CAACzB,IAAI,CAACE,OAAO,CAAC,CAAC;AAE5E;;;;;;AAMA,OAAO,MAAMwB,WAAW,GACtBxB,OAA8D,IAE9DP,KAAK,CAAC8B,aAAa,CACjBlC,MAAM,CAACoC,MAAM,CAACzB,OAAO,CAAC,CAACoB,IAAI,CACzB7B,MAAM,CAACmC,OAAO,CAAC5B,IAAI,CAAC,CACrB,CACF","ignoreList":[]}
|
package/dist/BunRuntime.d.ts
CHANGED
|
@@ -3,6 +3,11 @@ import type { Teardown } from "effect/Runtime";
|
|
|
3
3
|
/**
|
|
4
4
|
* Helps you run a main effect with built-in error handling, logging, and signal management.
|
|
5
5
|
*
|
|
6
|
+
* **When to use**
|
|
7
|
+
*
|
|
8
|
+
* Use to run a Bun application's main Effect with structured error handling,
|
|
9
|
+
* log management, interrupt support, or advanced teardown capabilities.
|
|
10
|
+
*
|
|
6
11
|
* **Details**
|
|
7
12
|
*
|
|
8
13
|
* This function launches an Effect as the main entry point, setting exit codes
|
|
@@ -11,26 +16,23 @@ import type { Teardown } from "effect/Runtime";
|
|
|
11
16
|
* behaviors can be turned off. You can also provide custom teardown logic to
|
|
12
17
|
* finalize resources or produce different exit codes.
|
|
13
18
|
*
|
|
14
|
-
* **Options**
|
|
15
|
-
*
|
|
16
19
|
* An optional object that can include:
|
|
17
20
|
* - `disableErrorReporting`: Turn off automatic error logging.
|
|
18
21
|
* - `disablePrettyLogger`: Avoid adding the pretty logger.
|
|
19
22
|
* - `teardown`: Provide custom finalization logic.
|
|
20
23
|
*
|
|
21
|
-
*
|
|
22
|
-
*
|
|
23
|
-
* Use this function to run an Effect as your application’s main program, especially
|
|
24
|
-
* when you need structured error handling, log management, interrupt support,
|
|
25
|
-
* or advanced teardown capabilities.
|
|
26
|
-
*
|
|
27
|
-
* @since 1.0.0
|
|
28
|
-
* @category Run main
|
|
24
|
+
* @category running
|
|
25
|
+
* @since 4.0.0
|
|
29
26
|
*/
|
|
30
27
|
export declare const runMain: {
|
|
31
28
|
/**
|
|
32
29
|
* Helps you run a main effect with built-in error handling, logging, and signal management.
|
|
33
30
|
*
|
|
31
|
+
* **When to use**
|
|
32
|
+
*
|
|
33
|
+
* Use to run a Bun application's main Effect with structured error handling,
|
|
34
|
+
* log management, interrupt support, or advanced teardown capabilities.
|
|
35
|
+
*
|
|
34
36
|
* **Details**
|
|
35
37
|
*
|
|
36
38
|
* This function launches an Effect as the main entry point, setting exit codes
|
|
@@ -39,21 +41,13 @@ export declare const runMain: {
|
|
|
39
41
|
* behaviors can be turned off. You can also provide custom teardown logic to
|
|
40
42
|
* finalize resources or produce different exit codes.
|
|
41
43
|
*
|
|
42
|
-
* **Options**
|
|
43
|
-
*
|
|
44
44
|
* An optional object that can include:
|
|
45
45
|
* - `disableErrorReporting`: Turn off automatic error logging.
|
|
46
46
|
* - `disablePrettyLogger`: Avoid adding the pretty logger.
|
|
47
47
|
* - `teardown`: Provide custom finalization logic.
|
|
48
48
|
*
|
|
49
|
-
*
|
|
50
|
-
*
|
|
51
|
-
* Use this function to run an Effect as your application’s main program, especially
|
|
52
|
-
* when you need structured error handling, log management, interrupt support,
|
|
53
|
-
* or advanced teardown capabilities.
|
|
54
|
-
*
|
|
55
|
-
* @since 1.0.0
|
|
56
|
-
* @category Run main
|
|
49
|
+
* @category running
|
|
50
|
+
* @since 4.0.0
|
|
57
51
|
*/
|
|
58
52
|
(options?: {
|
|
59
53
|
readonly disableErrorReporting?: boolean | undefined;
|
|
@@ -62,6 +56,11 @@ export declare const runMain: {
|
|
|
62
56
|
/**
|
|
63
57
|
* Helps you run a main effect with built-in error handling, logging, and signal management.
|
|
64
58
|
*
|
|
59
|
+
* **When to use**
|
|
60
|
+
*
|
|
61
|
+
* Use to run a Bun application's main Effect with structured error handling,
|
|
62
|
+
* log management, interrupt support, or advanced teardown capabilities.
|
|
63
|
+
*
|
|
65
64
|
* **Details**
|
|
66
65
|
*
|
|
67
66
|
* This function launches an Effect as the main entry point, setting exit codes
|
|
@@ -70,21 +69,13 @@ export declare const runMain: {
|
|
|
70
69
|
* behaviors can be turned off. You can also provide custom teardown logic to
|
|
71
70
|
* finalize resources or produce different exit codes.
|
|
72
71
|
*
|
|
73
|
-
* **Options**
|
|
74
|
-
*
|
|
75
72
|
* An optional object that can include:
|
|
76
73
|
* - `disableErrorReporting`: Turn off automatic error logging.
|
|
77
74
|
* - `disablePrettyLogger`: Avoid adding the pretty logger.
|
|
78
75
|
* - `teardown`: Provide custom finalization logic.
|
|
79
76
|
*
|
|
80
|
-
*
|
|
81
|
-
*
|
|
82
|
-
* Use this function to run an Effect as your application’s main program, especially
|
|
83
|
-
* when you need structured error handling, log management, interrupt support,
|
|
84
|
-
* or advanced teardown capabilities.
|
|
85
|
-
*
|
|
86
|
-
* @since 1.0.0
|
|
87
|
-
* @category Run main
|
|
77
|
+
* @category running
|
|
78
|
+
* @since 4.0.0
|
|
88
79
|
*/
|
|
89
80
|
<E, A>(effect: Effect<A, E>, options?: {
|
|
90
81
|
readonly disableErrorReporting?: boolean | undefined;
|
package/dist/BunRuntime.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BunRuntime.d.ts","sourceRoot":"","sources":["../src/BunRuntime.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"BunRuntime.d.ts","sourceRoot":"","sources":["../src/BunRuntime.ts"],"names":[],"mappings":"AAUA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,eAAe,CAAA;AAC3C,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAA;AAE9C;;;;;;;;;;;;;;;;;;;;;;;GAuBG;AACH,eAAO,MAAM,OAAO,EAAE;IACpB;;;;;;;;;;;;;;;;;;;;;;;OAuBG;IACH,CACE,OAAO,CAAC,EAAE;QACR,QAAQ,CAAC,qBAAqB,CAAC,EAAE,OAAO,GAAG,SAAS,CAAA;QACpD,QAAQ,CAAC,QAAQ,CAAC,EAAE,QAAQ,GAAG,SAAS,CAAA;KACzC,GACA,CAAC,CAAC,EAAE,CAAC,EAAE,MAAM,EAAE,MAAM,CAAC,CAAC,EAAE,CAAC,CAAC,KAAK,IAAI,CAAA;IACvC;;;;;;;;;;;;;;;;;;;;;;;OAuBG;IACH,CAAC,CAAC,EAAE,CAAC,EACH,MAAM,EAAE,MAAM,CAAC,CAAC,EAAE,CAAC,CAAC,EACpB,OAAO,CAAC,EAAE;QACR,QAAQ,CAAC,qBAAqB,CAAC,EAAE,OAAO,GAAG,SAAS,CAAA;QACpD,QAAQ,CAAC,QAAQ,CAAC,EAAE,QAAQ,GAAG,SAAS,CAAA;KACzC,GACA,IAAI,CAAA;CACc,CAAA"}
|
package/dist/BunRuntime.js
CHANGED
|
@@ -1,10 +1,21 @@
|
|
|
1
1
|
/**
|
|
2
|
-
*
|
|
2
|
+
* Bun process runner for Effect programs.
|
|
3
|
+
*
|
|
4
|
+
* This module exports `runMain`, which runs one Effect as the main process
|
|
5
|
+
* fiber in Bun. It reuses the shared Node runtime runner, including its error
|
|
6
|
+
* reporting, signal handling, and optional teardown behavior.
|
|
7
|
+
*
|
|
8
|
+
* @since 4.0.0
|
|
3
9
|
*/
|
|
4
10
|
import * as NodeRuntime from "@effect/platform-node-shared/NodeRuntime";
|
|
5
11
|
/**
|
|
6
12
|
* Helps you run a main effect with built-in error handling, logging, and signal management.
|
|
7
13
|
*
|
|
14
|
+
* **When to use**
|
|
15
|
+
*
|
|
16
|
+
* Use to run a Bun application's main Effect with structured error handling,
|
|
17
|
+
* log management, interrupt support, or advanced teardown capabilities.
|
|
18
|
+
*
|
|
8
19
|
* **Details**
|
|
9
20
|
*
|
|
10
21
|
* This function launches an Effect as the main entry point, setting exit codes
|
|
@@ -13,21 +24,13 @@ import * as NodeRuntime from "@effect/platform-node-shared/NodeRuntime";
|
|
|
13
24
|
* behaviors can be turned off. You can also provide custom teardown logic to
|
|
14
25
|
* finalize resources or produce different exit codes.
|
|
15
26
|
*
|
|
16
|
-
* **Options**
|
|
17
|
-
*
|
|
18
27
|
* An optional object that can include:
|
|
19
28
|
* - `disableErrorReporting`: Turn off automatic error logging.
|
|
20
29
|
* - `disablePrettyLogger`: Avoid adding the pretty logger.
|
|
21
30
|
* - `teardown`: Provide custom finalization logic.
|
|
22
31
|
*
|
|
23
|
-
*
|
|
24
|
-
*
|
|
25
|
-
* Use this function to run an Effect as your application’s main program, especially
|
|
26
|
-
* when you need structured error handling, log management, interrupt support,
|
|
27
|
-
* or advanced teardown capabilities.
|
|
28
|
-
*
|
|
29
|
-
* @since 1.0.0
|
|
30
|
-
* @category Run main
|
|
32
|
+
* @category running
|
|
33
|
+
* @since 4.0.0
|
|
31
34
|
*/
|
|
32
35
|
export const runMain = NodeRuntime.runMain;
|
|
33
36
|
//# sourceMappingURL=BunRuntime.js.map
|
package/dist/BunRuntime.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BunRuntime.js","names":["NodeRuntime","runMain"],"sources":["../src/BunRuntime.ts"],"sourcesContent":[null],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"BunRuntime.js","names":["NodeRuntime","runMain"],"sources":["../src/BunRuntime.ts"],"sourcesContent":[null],"mappings":"AAAA;;;;;;;;;AASA,OAAO,KAAKA,WAAW,MAAM,0CAA0C;AAIvE;;;;;;;;;;;;;;;;;;;;;;;;AAwBA,OAAO,MAAMC,OAAO,GA8DhBD,WAAW,CAACC,OAAO","ignoreList":[]}
|
package/dist/BunServices.d.ts
CHANGED
|
@@ -1,6 +1,14 @@
|
|
|
1
1
|
/**
|
|
2
|
-
*
|
|
2
|
+
* Aggregate Bun platform services layer.
|
|
3
|
+
*
|
|
4
|
+
* This module defines the `BunServices` union and a single `layer` that
|
|
5
|
+
* provides Bun-backed child process spawning, crypto, filesystem, path, stdio,
|
|
6
|
+
* and terminal services. Use the layer when a Bun program wants the standard
|
|
7
|
+
* platform services from one place.
|
|
8
|
+
*
|
|
9
|
+
* @since 4.0.0
|
|
3
10
|
*/
|
|
11
|
+
import type { Crypto } from "effect/Crypto";
|
|
4
12
|
import type { FileSystem } from "effect/FileSystem";
|
|
5
13
|
import * as Layer from "effect/Layer";
|
|
6
14
|
import type { Path } from "effect/Path";
|
|
@@ -8,13 +16,19 @@ import type { Stdio } from "effect/Stdio";
|
|
|
8
16
|
import type { Terminal } from "effect/Terminal";
|
|
9
17
|
import type { ChildProcessSpawner } from "effect/unstable/process/ChildProcessSpawner";
|
|
10
18
|
/**
|
|
11
|
-
*
|
|
19
|
+
* The union of core services provided by the Bun platform layer, including child
|
|
20
|
+
* process spawning, filesystem, path, stdio, and terminal services.
|
|
21
|
+
*
|
|
12
22
|
* @category models
|
|
23
|
+
* @since 4.0.0
|
|
13
24
|
*/
|
|
14
|
-
export type BunServices = ChildProcessSpawner | FileSystem | Path | Terminal | Stdio;
|
|
25
|
+
export type BunServices = ChildProcessSpawner | Crypto | FileSystem | Path | Terminal | Stdio;
|
|
15
26
|
/**
|
|
16
|
-
*
|
|
17
|
-
*
|
|
27
|
+
* Provides the default Bun implementations for child process spawning,
|
|
28
|
+
* filesystem, path, stdio, and terminal services.
|
|
29
|
+
*
|
|
30
|
+
* @category layers
|
|
31
|
+
* @since 4.0.0
|
|
18
32
|
*/
|
|
19
33
|
export declare const layer: Layer.Layer<BunServices>;
|
|
20
34
|
//# sourceMappingURL=BunServices.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BunServices.d.ts","sourceRoot":"","sources":["../src/BunServices.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"BunServices.d.ts","sourceRoot":"","sources":["../src/BunServices.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AACH,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,eAAe,CAAA;AAC3C,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAA;AACnD,OAAO,KAAK,KAAK,MAAM,cAAc,CAAA;AACrC,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,aAAa,CAAA;AACvC,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,cAAc,CAAA;AACzC,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,iBAAiB,CAAA;AAC/C,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,6CAA6C,CAAA;AAQtF;;;;;;GAMG;AACH,MAAM,MAAM,WAAW,GAAG,mBAAmB,GAAG,MAAM,GAAG,UAAU,GAAG,IAAI,GAAG,QAAQ,GAAG,KAAK,CAAA;AAE7F;;;;;;GAMG;AACH,eAAO,MAAM,KAAK,EAAE,KAAK,CAAC,KAAK,CAAC,WAAW,CAQ1C,CAAA"}
|
package/dist/BunServices.js
CHANGED
|
@@ -1,12 +1,16 @@
|
|
|
1
1
|
import * as Layer from "effect/Layer";
|
|
2
2
|
import * as BunChildProcessSpawner from "./BunChildProcessSpawner.js";
|
|
3
|
+
import * as BunCrypto from "./BunCrypto.js";
|
|
3
4
|
import * as BunFileSystem from "./BunFileSystem.js";
|
|
4
5
|
import * as BunPath from "./BunPath.js";
|
|
5
6
|
import * as BunStdio from "./BunStdio.js";
|
|
6
7
|
import * as BunTerminal from "./BunTerminal.js";
|
|
7
8
|
/**
|
|
8
|
-
*
|
|
9
|
-
*
|
|
9
|
+
* Provides the default Bun implementations for child process spawning,
|
|
10
|
+
* filesystem, path, stdio, and terminal services.
|
|
11
|
+
*
|
|
12
|
+
* @category layers
|
|
13
|
+
* @since 4.0.0
|
|
10
14
|
*/
|
|
11
|
-
export const layer = /*#__PURE__*/BunChildProcessSpawner.layer.pipe(/*#__PURE__*/Layer.provideMerge(/*#__PURE__*/Layer.mergeAll(BunFileSystem.layer, BunPath.layer, BunStdio.layer, BunTerminal.layer)));
|
|
15
|
+
export const layer = /*#__PURE__*/BunChildProcessSpawner.layer.pipe(/*#__PURE__*/Layer.provideMerge(/*#__PURE__*/Layer.mergeAll(BunFileSystem.layer, BunCrypto.layer, BunPath.layer, BunStdio.layer, BunTerminal.layer)));
|
|
12
16
|
//# sourceMappingURL=BunServices.js.map
|
package/dist/BunServices.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BunServices.js","names":["Layer","BunChildProcessSpawner","BunFileSystem","BunPath","BunStdio","BunTerminal","layer","pipe","provideMerge","mergeAll"],"sources":["../src/BunServices.ts"],"sourcesContent":[null],"mappings":"
|
|
1
|
+
{"version":3,"file":"BunServices.js","names":["Layer","BunChildProcessSpawner","BunCrypto","BunFileSystem","BunPath","BunStdio","BunTerminal","layer","pipe","provideMerge","mergeAll"],"sources":["../src/BunServices.ts"],"sourcesContent":[null],"mappings":"AAYA,OAAO,KAAKA,KAAK,MAAM,cAAc;AAKrC,OAAO,KAAKC,sBAAsB,MAAM,6BAA6B;AACrE,OAAO,KAAKC,SAAS,MAAM,gBAAgB;AAC3C,OAAO,KAAKC,aAAa,MAAM,oBAAoB;AACnD,OAAO,KAAKC,OAAO,MAAM,cAAc;AACvC,OAAO,KAAKC,QAAQ,MAAM,eAAe;AACzC,OAAO,KAAKC,WAAW,MAAM,kBAAkB;AAW/C;;;;;;;AAOA,OAAO,MAAMC,KAAK,gBAA6BN,sBAAsB,CAACM,KAAK,CAACC,IAAI,cAC9ER,KAAK,CAACS,YAAY,cAACT,KAAK,CAACU,QAAQ,CAC/BP,aAAa,CAACI,KAAK,EACnBL,SAAS,CAACK,KAAK,EACfH,OAAO,CAACG,KAAK,EACbF,QAAQ,CAACE,KAAK,EACdD,WAAW,CAACC,KAAK,CAClB,CAAC,CACH","ignoreList":[]}
|
package/dist/BunSink.d.ts
CHANGED
package/dist/BunSink.js
CHANGED
package/dist/BunSocket.d.ts
CHANGED
|
@@ -1,22 +1,36 @@
|
|
|
1
1
|
/**
|
|
2
|
-
*
|
|
2
|
+
* Bun platform socket entry point for Effect sockets.
|
|
3
|
+
*
|
|
4
|
+
* This module re-exports the shared Node socket constructors for TCP clients,
|
|
5
|
+
* Unix domain socket clients, and adapters from existing Node `Duplex` streams.
|
|
6
|
+
* It also provides Bun WebSocket layers using `globalThis.WebSocket`, including
|
|
7
|
+
* a constructor layer and a `Socket.Socket` layer for a WebSocket URL.
|
|
8
|
+
*
|
|
9
|
+
* @since 4.0.0
|
|
3
10
|
*/
|
|
4
11
|
import type * as Duration from "effect/Duration";
|
|
5
12
|
import type { Effect } from "effect/Effect";
|
|
6
13
|
import * as Layer from "effect/Layer";
|
|
7
14
|
import * as Socket from "effect/unstable/socket/Socket";
|
|
8
15
|
/**
|
|
9
|
-
* @since
|
|
16
|
+
* @since 4.0.0
|
|
10
17
|
*/
|
|
11
18
|
export * from "@effect/platform-node-shared/NodeSocket";
|
|
12
19
|
/**
|
|
13
|
-
*
|
|
20
|
+
* Provides a `Socket.WebSocketConstructor` backed by Bun's global
|
|
21
|
+
* `WebSocket` implementation.
|
|
22
|
+
*
|
|
14
23
|
* @category layers
|
|
24
|
+
* @since 4.0.0
|
|
15
25
|
*/
|
|
16
26
|
export declare const layerWebSocketConstructor: Layer.Layer<Socket.WebSocketConstructor>;
|
|
17
27
|
/**
|
|
18
|
-
*
|
|
28
|
+
* Creates a `Socket.Socket` layer for a WebSocket URL using Bun's global
|
|
29
|
+
* `WebSocket` constructor, honoring protocol, open-timeout, and close-code
|
|
30
|
+
* error options.
|
|
31
|
+
*
|
|
19
32
|
* @category layers
|
|
33
|
+
* @since 4.0.0
|
|
20
34
|
*/
|
|
21
35
|
export declare const layerWebSocket: (url: string | Effect<string>, options?: {
|
|
22
36
|
readonly closeCodeIsError?: ((code: number) => boolean) | undefined;
|
package/dist/BunSocket.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BunSocket.d.ts","sourceRoot":"","sources":["../src/BunSocket.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"BunSocket.d.ts","sourceRoot":"","sources":["../src/BunSocket.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AACH,OAAO,KAAK,KAAK,QAAQ,MAAM,iBAAiB,CAAA;AAChD,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,eAAe,CAAA;AAE3C,OAAO,KAAK,KAAK,MAAM,cAAc,CAAA;AACrC,OAAO,KAAK,MAAM,MAAM,+BAA+B,CAAA;AAEvD;;GAEG;AACH,cAAc,yCAAyC,CAAA;AAEvD;;;;;;GAMG;AACH,eAAO,MAAM,yBAAyB,EAAE,KAAK,CAAC,KAAK,CACjD,MAAM,CAAC,oBAAoB,CAG5B,CAAA;AAED;;;;;;;GAOG;AACH,eAAO,MAAM,cAAc,EAAE,CAC3B,GAAG,EAAE,MAAM,GAAG,MAAM,CAAC,MAAM,CAAC,EAC5B,OAAO,CAAC,EAAE;IACR,QAAQ,CAAC,gBAAgB,CAAC,EAAE,CAAC,CAAC,IAAI,EAAE,MAAM,KAAK,OAAO,CAAC,GAAG,SAAS,CAAA;IACnE,QAAQ,CAAC,WAAW,CAAC,EAAE,QAAQ,CAAC,KAAK,GAAG,SAAS,CAAA;IACjD,QAAQ,CAAC,SAAS,CAAC,EAAE,MAAM,GAAG,KAAK,CAAC,MAAM,CAAC,GAAG,SAAS,CAAA;CACxD,GAAG,SAAS,KACV,KAAK,CAAC,KAAK,CAAC,MAAM,CAAC,MAAM,EAAE,KAAK,EAAE,KAAK,CAI3C,CAAA"}
|
package/dist/BunSocket.js
CHANGED
|
@@ -2,17 +2,24 @@ import { flow } from "effect/Function";
|
|
|
2
2
|
import * as Layer from "effect/Layer";
|
|
3
3
|
import * as Socket from "effect/unstable/socket/Socket";
|
|
4
4
|
/**
|
|
5
|
-
* @since
|
|
5
|
+
* @since 4.0.0
|
|
6
6
|
*/
|
|
7
7
|
export * from "@effect/platform-node-shared/NodeSocket";
|
|
8
8
|
/**
|
|
9
|
-
*
|
|
9
|
+
* Provides a `Socket.WebSocketConstructor` backed by Bun's global
|
|
10
|
+
* `WebSocket` implementation.
|
|
11
|
+
*
|
|
10
12
|
* @category layers
|
|
13
|
+
* @since 4.0.0
|
|
11
14
|
*/
|
|
12
15
|
export const layerWebSocketConstructor = /*#__PURE__*/Layer.succeed(Socket.WebSocketConstructor)((url, protocols) => new globalThis.WebSocket(url, protocols));
|
|
13
16
|
/**
|
|
14
|
-
*
|
|
17
|
+
* Creates a `Socket.Socket` layer for a WebSocket URL using Bun's global
|
|
18
|
+
* `WebSocket` constructor, honoring protocol, open-timeout, and close-code
|
|
19
|
+
* error options.
|
|
20
|
+
*
|
|
15
21
|
* @category layers
|
|
22
|
+
* @since 4.0.0
|
|
16
23
|
*/
|
|
17
24
|
export const layerWebSocket = /*#__PURE__*/flow(Socket.makeWebSocket, /*#__PURE__*/Layer.effect(Socket.Socket), /*#__PURE__*/Layer.provide(layerWebSocketConstructor));
|
|
18
25
|
//# sourceMappingURL=BunSocket.js.map
|
package/dist/BunSocket.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BunSocket.js","names":["flow","Layer","Socket","layerWebSocketConstructor","succeed","WebSocketConstructor","url","protocols","globalThis","WebSocket","layerWebSocket","makeWebSocket","effect","provide"],"sources":["../src/BunSocket.ts"],"sourcesContent":[null],"mappings":"
|
|
1
|
+
{"version":3,"file":"BunSocket.js","names":["flow","Layer","Socket","layerWebSocketConstructor","succeed","WebSocketConstructor","url","protocols","globalThis","WebSocket","layerWebSocket","makeWebSocket","effect","provide"],"sources":["../src/BunSocket.ts"],"sourcesContent":[null],"mappings":"AAYA,SAASA,IAAI,QAAQ,iBAAiB;AACtC,OAAO,KAAKC,KAAK,MAAM,cAAc;AACrC,OAAO,KAAKC,MAAM,MAAM,+BAA+B;AAEvD;;;AAGA,cAAc,yCAAyC;AAEvD;;;;;;;AAOA,OAAO,MAAMC,yBAAyB,gBAElCF,KAAK,CAACG,OAAO,CAACF,MAAM,CAACG,oBAAoB,CAAC,CAC5C,CAACC,GAAG,EAAEC,SAAS,KAAK,IAAIC,UAAU,CAACC,SAAS,CAACH,GAAG,EAAEC,SAAS,CAAC,CAC7D;AAED;;;;;;;;AAQA,OAAO,MAAMG,cAAc,gBAOqBV,IAAI,CAClDE,MAAM,CAACS,aAAa,eACpBV,KAAK,CAACW,MAAM,CAACV,MAAM,CAACA,MAAM,CAAC,eAC3BD,KAAK,CAACY,OAAO,CAACV,yBAAyB,CAAC,CACzC","ignoreList":[]}
|
package/dist/BunSocketServer.js
CHANGED
package/dist/BunStdio.d.ts
CHANGED
|
@@ -1,8 +1,11 @@
|
|
|
1
1
|
import type * as Layer from "effect/Layer";
|
|
2
2
|
import type { Stdio } from "effect/Stdio";
|
|
3
3
|
/**
|
|
4
|
-
*
|
|
5
|
-
*
|
|
4
|
+
* Provides the `Stdio` service backed by the current process arguments,
|
|
5
|
+
* stdin, stdout, and stderr streams.
|
|
6
|
+
*
|
|
7
|
+
* @category layers
|
|
8
|
+
* @since 4.0.0
|
|
6
9
|
*/
|
|
7
10
|
export declare const layer: Layer.Layer<Stdio>;
|
|
8
11
|
//# sourceMappingURL=BunStdio.d.ts.map
|
package/dist/BunStdio.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BunStdio.d.ts","sourceRoot":"","sources":["../src/BunStdio.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"BunStdio.d.ts","sourceRoot":"","sources":["../src/BunStdio.ts"],"names":[],"mappings":"AAWA,OAAO,KAAK,KAAK,KAAK,MAAM,cAAc,CAAA;AAC1C,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,cAAc,CAAA;AAEzC;;;;;;GAMG;AACH,eAAO,MAAM,KAAK,EAAE,KAAK,CAAC,KAAK,CAAC,KAAK,CAAmB,CAAA"}
|
package/dist/BunStdio.js
CHANGED
|
@@ -1,10 +1,20 @@
|
|
|
1
1
|
/**
|
|
2
|
-
*
|
|
2
|
+
* Process stdio for Bun applications.
|
|
3
|
+
*
|
|
4
|
+
* This module provides the Bun layer for Effect's `Stdio` service by using the
|
|
5
|
+
* shared Node stdio implementation. Arguments come from `process.argv`, input
|
|
6
|
+
* is read from `process.stdin`, and output and error output write to
|
|
7
|
+
* `process.stdout` and `process.stderr`.
|
|
8
|
+
*
|
|
9
|
+
* @since 4.0.0
|
|
3
10
|
*/
|
|
4
11
|
import * as NodeStdio from "@effect/platform-node-shared/NodeStdio";
|
|
5
12
|
/**
|
|
6
|
-
*
|
|
7
|
-
*
|
|
13
|
+
* Provides the `Stdio` service backed by the current process arguments,
|
|
14
|
+
* stdin, stdout, and stderr streams.
|
|
15
|
+
*
|
|
16
|
+
* @category layers
|
|
17
|
+
* @since 4.0.0
|
|
8
18
|
*/
|
|
9
19
|
export const layer = NodeStdio.layer;
|
|
10
20
|
//# sourceMappingURL=BunStdio.js.map
|
package/dist/BunStdio.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BunStdio.js","names":["NodeStdio","layer"],"sources":["../src/BunStdio.ts"],"sourcesContent":[null],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"BunStdio.js","names":["NodeStdio","layer"],"sources":["../src/BunStdio.ts"],"sourcesContent":[null],"mappings":"AAAA;;;;;;;;;;AAUA,OAAO,KAAKA,SAAS,MAAM,wCAAwC;AAInE;;;;;;;AAOA,OAAO,MAAMC,KAAK,GAAuBD,SAAS,CAACC,KAAK","ignoreList":[]}
|
package/dist/BunStream.d.ts
CHANGED
|
@@ -1,14 +1,15 @@
|
|
|
1
1
|
import type { LazyArg } from "effect/Function";
|
|
2
2
|
import * as Stream from "effect/Stream";
|
|
3
3
|
/**
|
|
4
|
-
* @since
|
|
4
|
+
* @since 4.0.0
|
|
5
5
|
*/
|
|
6
6
|
export * from "@effect/platform-node-shared/NodeStream";
|
|
7
7
|
/**
|
|
8
|
-
*
|
|
9
|
-
* .
|
|
8
|
+
* Creates a stream from a `ReadableStream` using Bun's optimized `.readMany`
|
|
9
|
+
* API.
|
|
10
10
|
*
|
|
11
|
-
* @
|
|
11
|
+
* @category constructors
|
|
12
|
+
* @since 4.0.0
|
|
12
13
|
*/
|
|
13
14
|
export declare const fromReadableStream: <A, E>(options: {
|
|
14
15
|
readonly evaluate: LazyArg<ReadableStream<A>>;
|