This commit is contained in:
Dax Raad
2026-05-22 10:07:53 -04:00
parent 36160ef28f
commit eaf5697b06
11 changed files with 420 additions and 320 deletions
+2
View File
@@ -3,6 +3,8 @@ import { AccountV2 } from "../account"
import { EventV2 } from "../event"
import { PluginV2 } from "../plugin"
// Depending on what account is active, enable matching providers for that
// service
export const AccountPlugin = PluginV2.define({
id: PluginV2.ID.make("account"),
effect: Effect.gen(function* () {
+1 -2
View File
@@ -56,7 +56,6 @@ export const ModelsDevPlugin = PluginV2.define({
const catalog = yield* Catalog.Service
const modelsDev = yield* ModelsDev.Service
const events = yield* EventV2.Service
const scope = yield* Scope.Scope
const load = yield* catalog.loader()
const refresh = Effect.fn("ModelsDevPlugin.refresh")(function* () {
const data = yield* modelsDev.get()
@@ -114,7 +113,7 @@ export const ModelsDevPlugin = PluginV2.define({
yield* refresh()
yield* events.subscribe(ModelsDev.Event.Refreshed).pipe(
Stream.runForEach(() => refresh()),
Effect.forkIn(scope, { startImmediately: true }),
Effect.forkScoped({ startImmediately: true }),
)
}).pipe(Effect.provide(ModelsDev.defaultLayer)),
})