{
  "id": "@typed/fx/Subject#unsafeMake",
  "canonicalId": "@typed/fx/Subject#unsafeMake",
  "symbol": {
    "id": "@typed/fx/Subject#unsafeMake",
    "packageName": "@typed/fx",
    "moduleName": "Subject",
    "exportName": "unsafeMake",
    "kind": "function",
    "signatures": [
      "export declare function unsafeMake<A, E = never>(replay?: number): Subject<A, E>;"
    ],
    "summary": "Immediately allocates a `Subject` with the requested replay capacity and manual ownership.",
    "sections": {
      "Why": "`unsafeMake` is the escape hatch for owners that cannot acquire through an Effect `Scope`, such\nas a long-lived host object with its own explicit teardown. Prefer `make` inside Effect programs.",
      "Ownership and lifetime": "Allocation is synchronous and starts no fibers. The caller must execute `interrupt` to close\nsubscribers and clear retained `Exit` values. Capacity `0` retains nothing, capacity `1` retains\nthe latest publication, and larger capacities retain the newest window in FIFO replay order.",
      "Errors": "Invalid capacities throw `Cause.IllegalArgumentError` synchronously; this function has no typed\nEffect error channel. Publishing and subscribing use the `E` and service channels of the returned\nsubject."
    },
    "examples": [
      {
        "language": "ts",
        "code": "import { Effect } from \"effect\"\nimport * as Subject from \"@typed/fx/Subject\"\n\nconst events = Subject.unsafeMake<string>(10)\n\nconst shutdown = events.interrupt\nconst publish = events.onSuccess(\"ready\").pipe(Effect.asVoid)"
      }
    ],
    "relations": [],
    "source": {
      "file": "packages/fx/src/Subject/Subject.ts",
      "line": 1390
    },
    "since": "1.0.0",
    "category": "Subject construction"
  },
  "exposure": {
    "recordKind": "declaration",
    "id": "@typed/fx/Subject#unsafeMake",
    "packageName": "@typed/fx",
    "packageVersion": "2.0.0-beta.7",
    "moduleName": "Subject",
    "consumerSpecifier": "@typed/fx/Subject",
    "exportName": "unsafeMake",
    "qualifiedName": "unsafeMake",
    "declarationKey": "declaration:0aa3724b8cbe809d79837793",
    "family": "function",
    "signatures": [
      "export declare function unsafeMake<A, E = never>(replay?: number): Subject<A, E>;"
    ],
    "sourceSpans": [
      {
        "file": "packages/fx/src/Subject/Subject.ts",
        "start": {
          "line": 1390,
          "column": 1
        },
        "end": {
          "line": 1402,
          "column": 2
        }
      }
    ],
    "aliases": [
      "@typed/fx#Subject.unsafeMake"
    ],
    "isAlias": false,
    "static": false
  },
  "declaration": {
    "declarationKey": "declaration:0aa3724b8cbe809d79837793",
    "name": "unsafeMake",
    "family": "function",
    "facets": [
      {
        "family": "function",
        "syntaxKind": "FunctionDeclaration",
        "signatures": [
          "export declare function unsafeMake<A, E = never>(replay?: number): Subject<A, E>;"
        ],
        "typeParameters": [
          "A",
          "E = never"
        ],
        "sourceSpans": [
          {
            "file": "packages/fx/src/Subject/Subject.ts",
            "start": {
              "line": 1390,
              "column": 1
            },
            "end": {
              "line": 1402,
              "column": 2
            }
          }
        ],
        "static": false,
        "readonly": false,
        "optional": false
      }
    ],
    "signatures": [
      "export declare function unsafeMake<A, E = never>(replay?: number): Subject<A, E>;"
    ],
    "typeParameters": [
      "A",
      "E = never"
    ],
    "summary": "Immediately allocates a `Subject` with the requested replay capacity and manual ownership.",
    "sections": {
      "Why": "`unsafeMake` is the escape hatch for owners that cannot acquire through an Effect `Scope`, such\nas a long-lived host object with its own explicit teardown. Prefer `make` inside Effect programs.",
      "Ownership and lifetime": "Allocation is synchronous and starts no fibers. The caller must execute `interrupt` to close\nsubscribers and clear retained `Exit` values. Capacity `0` retains nothing, capacity `1` retains\nthe latest publication, and larger capacities retain the newest window in FIFO replay order.",
      "Errors": "Invalid capacities throw `Cause.IllegalArgumentError` synchronously; this function has no typed\nEffect error channel. Publishing and subscribing use the `E` and service channels of the returned\nsubject."
    },
    "examples": [
      {
        "language": "ts",
        "code": "import { Effect } from \"effect\"\nimport * as Subject from \"@typed/fx/Subject\"\n\nconst events = Subject.unsafeMake<string>(10)\n\nconst shutdown = events.interrupt\nconst publish = events.onSuccess(\"ready\").pipe(Effect.asVoid)"
      }
    ],
    "sourceSpans": [
      {
        "file": "packages/fx/src/Subject/Subject.ts",
        "start": {
          "line": 1390,
          "column": 1
        },
        "end": {
          "line": 1402,
          "column": 2
        }
      }
    ],
    "since": "1.0.0",
    "category": "Subject construction"
  }
}
