Effection Logo

Experimental

This API is exported from effection/experimental and may change or be removed in a future release.

variable api

thefrontside/effection

const api: Apis

Built-in APIs used by Effection's runtime and host integrations.

Advanced integrations can decorate these APIs to observe or modify runtime behavior within a scope.

Examples

Example 1

import { main, useScope } from "effection";
import { api } from "effection/experimental";

await main(function* () {
  let scope = yield* useScope();

  scope.around(api.Scope, {
    create(args, next) {
      console.log("creating scope");
      return next(...args);
    },
  });
});

Type

Apis