Skip to content

Commit a214b88

Browse files
committed
docs: add module js doc
1 parent f1a965d commit a214b88

25 files changed

+345
-5
lines changed

deno.json

+5-4
Original file line numberDiff line numberDiff line change
@@ -22,16 +22,17 @@
2222
"./effect/typeclass": "./effect/typeclass.ts",
2323
"./option-t": "./option-t.ts",
2424
"./option-t/effect": "./option-t/effect.ts",
25-
"./option-t/safe-try": "./option-t/safe-try.ts"
25+
"./option-t/safe-try": "./option-t/safe-try.ts",
26+
"./test": "./test.ts"
2627
},
2728
"license": "MIT",
2829
"lock": false,
2930
"name": "@totto/function",
3031
"tasks": {
3132
"build": "deno publish --dry-run --allow-dirty",
3233
"fix": "deno check **/*.ts && deno fmt && deno lint",
33-
"test": "deno test **/*.test.ts",
34-
"precommit": "deno task fix && deno task build && deno task test"
34+
"precommit": "deno task fix && deno task build && deno task test",
35+
"test": "deno test **/*.test.ts"
3536
},
36-
"version": "0.1.0"
37+
"version": "0.1.1"
3738
}

effect.ts

+11
Original file line numberDiff line numberDiff line change
@@ -1 +1,12 @@
1+
/**
2+
* @module
3+
*
4+
* Re-exports of `effect` modules.
5+
*
6+
* @example
7+
* ```ts
8+
* import { Effect } from "@totto/function/effect";
9+
* ```
10+
*/
11+
112
export * from "npm:[email protected]";

effect/ai.ts

+11
Original file line numberDiff line numberDiff line change
@@ -1 +1,12 @@
1+
/**
2+
* @module
3+
*
4+
* Re-exports of `@effect/ai` modules.
5+
*
6+
* @example
7+
* ```ts
8+
* import { Ai } from "@totto/function/effect/ai";
9+
* ```
10+
*/
11+
112
export * from "npm:@effect/[email protected]";

effect/ai/anthropic.ts

+11
Original file line numberDiff line numberDiff line change
@@ -1 +1,12 @@
1+
/**
2+
* @module
3+
*
4+
* Re-exports of `@effect/ai-anthropic` modules.
5+
*
6+
* @example
7+
* ```ts
8+
* import { Anthropic } from "@totto/function/effect/ai/anthropic";
9+
* ```
10+
*/
11+
112
export * from "npm:@effect/[email protected]";

effect/ai/openai.ts

+11
Original file line numberDiff line numberDiff line change
@@ -1 +1,12 @@
1+
/**
2+
* @module
3+
*
4+
* Re-exports of `@effect/ai-openai` modules.
5+
*
6+
* @example
7+
* ```ts
8+
* import { Openai } from "@totto/function/effect/ai/openai";
9+
* ```
10+
*/
11+
112
export * from "npm:@effect/[email protected]";

effect/cli.ts

+11
Original file line numberDiff line numberDiff line change
@@ -1 +1,12 @@
1+
/**
2+
* @module
3+
*
4+
* Re-exports of `@effect/cli` modules.
5+
*
6+
* @example
7+
* ```ts
8+
* import { Cli } from "@totto/function/effect/cli";
9+
* ```
10+
*/
11+
112
export * from "npm:@effect/[email protected]";

effect/experimental/deps.ts

+6
Original file line numberDiff line numberDiff line change
@@ -1 +1,7 @@
1+
/**
2+
* @module
3+
*
4+
* Re-exports of Effect's experimental modules.
5+
*/
6+
17
export * from "npm:@effect/[email protected]";

effect/experimental/machine.ts

+11
Original file line numberDiff line numberDiff line change
@@ -1 +1,12 @@
1+
/**
2+
* @module
3+
*
4+
* Re-exports of Effect's experimental `Machine` module.
5+
*
6+
* @example
7+
* ```ts
8+
* import { Machine } from "@totto/function/effect/experimental/machine";
9+
* ```
10+
*/
11+
112
export { Machine } from "./deps.ts";

effect/opentelemetry.ts

+11
Original file line numberDiff line numberDiff line change
@@ -1 +1,12 @@
1+
/**
2+
* @module
3+
*
4+
* Re-exports of `@effect/opentelemetry` modules.
5+
*
6+
* @example
7+
* ```ts
8+
* import { Opentelemetry } from "@totto/function/effect/opentelemetry";
9+
* ```
10+
*/
11+
112
export * from "npm:@effect/[email protected]";

effect/option-t.ts

+16
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,22 @@
1+
/**
2+
* @module
3+
*
4+
* Converts Option-t's `Result` to Effect's `Exit`.
5+
*
6+
* @example
7+
* ```ts
8+
* import { fromResult } from "@totto/function/effect/option-t";
9+
*
10+
* const exit = fromResult(Result.createOk("success"));
11+
* // exit: Exit.Success("success")
12+
* ```
13+
*/
114
import { Result } from "../option-t.ts";
215
import { Exit } from "../effect.ts";
316

17+
/**
18+
* Converts an Option-t's `Result` object into an Effect's `Exit` object.
19+
*/
420
export function fromResult<OK, ERR>(
521
result: Result.Result<OK, ERR>,
622
): Exit.Exit<OK, ERR> {

effect/platform.ts

+11
Original file line numberDiff line numberDiff line change
@@ -1 +1,12 @@
1+
/**
2+
* @module
3+
*
4+
* Re-exports of `@effect/platform` modules.
5+
*
6+
* @example
7+
* ```ts
8+
* import { Platform } from "@totto/function/effect/platform";
9+
* ```
10+
*/
11+
112
export * from "npm:@effect/[email protected]";

effect/platform/browser.ts

+11
Original file line numberDiff line numberDiff line change
@@ -1 +1,12 @@
1+
/**
2+
* @module
3+
*
4+
* Re-exports of `@effect/platform-browser` modules.
5+
*
6+
* @example
7+
* ```ts
8+
* import { PlatformBrowser } from "@totto/function/effect/platform/browser";
9+
* ```
10+
*/
11+
112
export * from "npm:@effect/[email protected]";

effect/platform/bun.ts

+11
Original file line numberDiff line numberDiff line change
@@ -1 +1,12 @@
1+
/**
2+
* @module
3+
*
4+
* Re-exports of `@effect/platform-bun` modules.
5+
*
6+
* @example
7+
* ```ts
8+
* import { PlatformBun } from "@totto/function/effect/platform/bun";
9+
* ```
10+
*/
11+
112
export * from "npm:@effect/[email protected]";

effect/platform/node-share.ts

+11
Original file line numberDiff line numberDiff line change
@@ -1 +1,12 @@
1+
/**
2+
* @module
3+
*
4+
* Re-exports of `@effect/platform-node-shared` modules.
5+
*
6+
* @example
7+
* ```ts
8+
* import { PlatformNodeShared } from "@totto/function/effect/platform/node-share";
9+
* ```
10+
*/
11+
112
export * from "npm:@effect/[email protected]";

effect/platform/node.ts

+11
Original file line numberDiff line numberDiff line change
@@ -1 +1,12 @@
1+
/**
2+
* @module
3+
*
4+
* Re-exports of `@effect/platform-node` modules.
5+
*
6+
* @example
7+
* ```ts
8+
* import { PlatformNode } from "@totto/function/effect/platform/node";
9+
* ```
10+
*/
11+
112
export * from "npm:@effect/[email protected]";

effect/printer.ts

+11
Original file line numberDiff line numberDiff line change
@@ -1 +1,12 @@
1+
/**
2+
* @module
3+
*
4+
* Re-exports of `@effect/printer` modules.
5+
*
6+
* @example
7+
* ```ts
8+
* import { Printer } from "@totto/function/effect/printer";
9+
* ```
10+
*/
11+
112
export * from "npm:@effect/[email protected]";

effect/printer/ansi.ts

+11
Original file line numberDiff line numberDiff line change
@@ -1 +1,12 @@
1+
/**
2+
* @module
3+
*
4+
* Re-exports of `@effect/printer-ansi` modules.
5+
*
6+
* @example
7+
* ```ts
8+
* import { PrinterAnsi } from "@totto/function/effect/printer/ansi";
9+
* ```
10+
*/
11+
112
export * from "npm:@effect/[email protected]";

effect/rpc.ts

+11
Original file line numberDiff line numberDiff line change
@@ -1 +1,12 @@
1+
/**
2+
* @module
3+
*
4+
* Re-exports of `@effect/rpc` modules.
5+
*
6+
* @example
7+
* ```ts
8+
* import { Rpc } from "@totto/function/effect/rpc";
9+
* ```
10+
*/
11+
112
export * from "npm:@effect/[email protected]";

effect/rpc/http.ts

+11
Original file line numberDiff line numberDiff line change
@@ -1 +1,12 @@
1+
/**
2+
* @module
3+
*
4+
* Re-exports of `@effect/rpc-http` modules.
5+
*
6+
* @example
7+
* ```ts
8+
* import { RpcHttp } from "@totto/function/effect/rpc/http";
9+
* ```
10+
*/
11+
112
export * from "npm:@effect/[email protected]";

0 commit comments

Comments
 (0)