{
  "id": "@typed/fx#RefSubject.scanEffect",
  "canonicalId": "@typed/fx/RefSubject#scanEffect",
  "symbol": {
    "id": "@typed/fx#RefSubject.scanEffect",
    "packageName": "@typed/fx",
    "moduleName": ".",
    "exportName": "RefSubject.scanEffect",
    "kind": "constant",
    "signatures": [
      "export declare const scanEffect: {\n    <S, A, E3, R3>(initial: S, f: (s: S, a: A) => Effect.Effect<S, E3, R3>): <E, R>(ref: RefSubject<A, E, R> | Computed<A, E, R>) => Computed<S, E | E3, R | R3>;\n    <A, E, R, S, E3, R3>(ref: RefSubject<A, E, R> | Computed<A, E, R>, initial: S, f: (s: S, a: A) => Effect.Effect<S, E3, R3>): Computed<S, E | E3, R | R3>;\n    <R0, E0, A, E, R, E2, R2, S, E3, R3>(versioned: Versioned.Versioned<R0, E0, A, E, R, A, E2, R2>, initial: S, f: (s: S, a: A) => Effect.Effect<S, E3, R3>): Computed<S, E0 | E | E2 | E3, R0 | R2 | R3 | Exclude<R, Scope.Scope>>;\n};"
    ],
    "summary": "Effectful stateful scan over a `RefSubject` / `Computed`, producing a `Computed` of the accumulated state.",
    "sections": {
      "Why": "Effectful stateful scan over a `RefSubject` / `Computed`, producing a `Computed` of the\naccumulated state. The result remains a lazy view rather than a duplicated mutable value.",
      "Ownership and lifetime": "Each Effect Context object gets a private current-read accumulator. It advances only after `f`\nsucceeds, so a typed failure leaves the previous state intact. The pushed channel runs\n`Fx.scanEffect` from `initial` inside `Subject.hold`: observers using the same Context share\nthat active scan and retained result; each fold requires `R3`. The last observer ends its\nsession and clears its held value. The observing Scope owns cleanup. Read accumulators are\nweakly held by Context and need no finalizer."
    },
    "examples": [],
    "relations": [],
    "source": {
      "file": "packages/fx/src/RefSubject/RefSubject.ts",
      "line": 1016
    },
    "since": "1.0.0",
    "category": "Accumulation"
  },
  "exposure": {
    "recordKind": "declaration",
    "id": "@typed/fx#RefSubject.scanEffect",
    "packageName": "@typed/fx",
    "packageVersion": "2.0.0-beta.13",
    "moduleName": ".",
    "consumerSpecifier": "@typed/fx",
    "exportName": "RefSubject",
    "qualifiedName": "RefSubject.scanEffect",
    "declarationKey": "declaration:47e7dade79ff4eb4e4a2e544",
    "family": "variable",
    "signatures": [
      "export declare const scanEffect: {\n    <S, A, E3, R3>(initial: S, f: (s: S, a: A) => Effect.Effect<S, E3, R3>): <E, R>(ref: RefSubject<A, E, R> | Computed<A, E, R>) => Computed<S, E | E3, R | R3>;\n    <A, E, R, S, E3, R3>(ref: RefSubject<A, E, R> | Computed<A, E, R>, initial: S, f: (s: S, a: A) => Effect.Effect<S, E3, R3>): Computed<S, E | E3, R | R3>;\n    <R0, E0, A, E, R, E2, R2, S, E3, R3>(versioned: Versioned.Versioned<R0, E0, A, E, R, A, E2, R2>, initial: S, f: (s: S, a: A) => Effect.Effect<S, E3, R3>): Computed<S, E0 | E | E2 | E3, R0 | R2 | R3 | Exclude<R, Scope.Scope>>;\n};"
    ],
    "sourceSpans": [
      {
        "file": "packages/fx/src/RefSubject/RefSubject.ts",
        "start": {
          "line": 1016,
          "column": 14
        },
        "end": {
          "line": 1050,
          "column": 3
        }
      },
      {
        "file": "packages/fx/src/RefSubject/RefSubject.ts",
        "start": {
          "line": 1017,
          "column": 3
        },
        "end": {
          "line": 1020,
          "column": 90
        }
      },
      {
        "file": "packages/fx/src/RefSubject/RefSubject.ts",
        "start": {
          "line": 1022,
          "column": 3
        },
        "end": {
          "line": 1026,
          "column": 34
        }
      },
      {
        "file": "packages/fx/src/RefSubject/RefSubject.ts",
        "start": {
          "line": 1028,
          "column": 3
        },
        "end": {
          "line": 1032,
          "column": 76
        }
      }
    ],
    "aliases": [
      "@typed/fx/RefSubject#scanEffect"
    ],
    "isAlias": true,
    "parentId": "@typed/fx#RefSubject",
    "static": false,
    "importedFrom": "declaration:47e7dade79ff4eb4e4a2e544"
  },
  "declaration": {
    "declarationKey": "declaration:47e7dade79ff4eb4e4a2e544",
    "name": "scanEffect",
    "family": "variable",
    "facets": [
      {
        "family": "variable",
        "syntaxKind": "VariableDeclaration",
        "signatures": [
          "export declare const scanEffect: {\n    <S, A, E3, R3>(initial: S, f: (s: S, a: A) => Effect.Effect<S, E3, R3>): <E, R>(ref: RefSubject<A, E, R> | Computed<A, E, R>) => Computed<S, E | E3, R | R3>;\n    <A, E, R, S, E3, R3>(ref: RefSubject<A, E, R> | Computed<A, E, R>, initial: S, f: (s: S, a: A) => Effect.Effect<S, E3, R3>): Computed<S, E | E3, R | R3>;\n    <R0, E0, A, E, R, E2, R2, S, E3, R3>(versioned: Versioned.Versioned<R0, E0, A, E, R, A, E2, R2>, initial: S, f: (s: S, a: A) => Effect.Effect<S, E3, R3>): Computed<S, E0 | E | E2 | E3, R0 | R2 | R3 | Exclude<R, Scope.Scope>>;\n};"
        ],
        "typeParameters": [],
        "sourceSpans": [
          {
            "file": "packages/fx/src/RefSubject/RefSubject.ts",
            "start": {
              "line": 1016,
              "column": 14
            },
            "end": {
              "line": 1050,
              "column": 3
            }
          }
        ],
        "static": false,
        "readonly": false,
        "optional": false
      },
      {
        "family": "call-signature",
        "syntaxKind": "CallSignature",
        "signatures": [
          "<S, A, E3, R3>(initial: S, f: (s: S, a: A) => Effect.Effect<S, E3, R3>): <E, R>(ref: RefSubject<A, E, R> | Computed<A, E, R>) => Computed<S, E | E3, R | R3>;",
          "<A, E, R, S, E3, R3>(ref: RefSubject<A, E, R> | Computed<A, E, R>, initial: S, f: (s: S, a: A) => Effect.Effect<S, E3, R3>): Computed<S, E | E3, R | R3>;",
          "<R0, E0, A, E, R, E2, R2, S, E3, R3>(versioned: Versioned.Versioned<R0, E0, A, E, R, A, E2, R2>, initial: S, f: (s: S, a: A) => Effect.Effect<S, E3, R3>): Computed<S, E0 | E | E2 | E3, R0 | R2 | R3 | Exclude<R, Scope.Scope>>;"
        ],
        "typeParameters": [
          "S",
          "A",
          "E3",
          "R3",
          "E",
          "R",
          "R0",
          "E0",
          "E2",
          "R2"
        ],
        "sourceSpans": [
          {
            "file": "packages/fx/src/RefSubject/RefSubject.ts",
            "start": {
              "line": 1017,
              "column": 3
            },
            "end": {
              "line": 1020,
              "column": 90
            }
          },
          {
            "file": "packages/fx/src/RefSubject/RefSubject.ts",
            "start": {
              "line": 1022,
              "column": 3
            },
            "end": {
              "line": 1026,
              "column": 34
            }
          },
          {
            "file": "packages/fx/src/RefSubject/RefSubject.ts",
            "start": {
              "line": 1028,
              "column": 3
            },
            "end": {
              "line": 1032,
              "column": 76
            }
          }
        ],
        "static": false,
        "readonly": false,
        "optional": false
      }
    ],
    "signatures": [
      "export declare const scanEffect: {\n    <S, A, E3, R3>(initial: S, f: (s: S, a: A) => Effect.Effect<S, E3, R3>): <E, R>(ref: RefSubject<A, E, R> | Computed<A, E, R>) => Computed<S, E | E3, R | R3>;\n    <A, E, R, S, E3, R3>(ref: RefSubject<A, E, R> | Computed<A, E, R>, initial: S, f: (s: S, a: A) => Effect.Effect<S, E3, R3>): Computed<S, E | E3, R | R3>;\n    <R0, E0, A, E, R, E2, R2, S, E3, R3>(versioned: Versioned.Versioned<R0, E0, A, E, R, A, E2, R2>, initial: S, f: (s: S, a: A) => Effect.Effect<S, E3, R3>): Computed<S, E0 | E | E2 | E3, R0 | R2 | R3 | Exclude<R, Scope.Scope>>;\n};"
    ],
    "typeParameters": [
      "S",
      "A",
      "E3",
      "R3",
      "E",
      "R",
      "R0",
      "E0",
      "E2",
      "R2"
    ],
    "summary": "Effectful stateful scan over a `RefSubject` / `Computed`, producing a `Computed` of the accumulated state.",
    "sections": {
      "Why": "Effectful stateful scan over a `RefSubject` / `Computed`, producing a `Computed` of the\naccumulated state. The result remains a lazy view rather than a duplicated mutable value.",
      "Ownership and lifetime": "Each Effect Context object gets a private current-read accumulator. It advances only after `f`\nsucceeds, so a typed failure leaves the previous state intact. The pushed channel runs\n`Fx.scanEffect` from `initial` inside `Subject.hold`: observers using the same Context share\nthat active scan and retained result; each fold requires `R3`. The last observer ends its\nsession and clears its held value. The observing Scope owns cleanup. Read accumulators are\nweakly held by Context and need no finalizer."
    },
    "examples": [],
    "sourceSpans": [
      {
        "file": "packages/fx/src/RefSubject/RefSubject.ts",
        "start": {
          "line": 1016,
          "column": 14
        },
        "end": {
          "line": 1050,
          "column": 3
        }
      },
      {
        "file": "packages/fx/src/RefSubject/RefSubject.ts",
        "start": {
          "line": 1017,
          "column": 3
        },
        "end": {
          "line": 1020,
          "column": 90
        }
      },
      {
        "file": "packages/fx/src/RefSubject/RefSubject.ts",
        "start": {
          "line": 1022,
          "column": 3
        },
        "end": {
          "line": 1026,
          "column": 34
        }
      },
      {
        "file": "packages/fx/src/RefSubject/RefSubject.ts",
        "start": {
          "line": 1028,
          "column": 3
        },
        "end": {
          "line": 1032,
          "column": 76
        }
      }
    ],
    "since": "1.0.0",
    "category": "Accumulation"
  }
}
