Fix
Lint / lint (push) Successful in 39s

This commit is contained in:
Julien Valverdé
2026-07-19 03:15:55 +02:00
parent be1038fc8d
commit 9b25ef4b57
7 changed files with 10 additions and 273 deletions
+3 -14
View File
@@ -2,8 +2,6 @@
import { type Context, Effect, Layer, ManagedRuntime, Predicate } from "effect"
import * as React from "react"
import * as Component from "./Component.js"
import * as ErrorObserver from "./ErrorObserver.js"
import * as QueryClient from "./QueryClient.js"
export const ReactRuntimeTypeId: unique symbol = Symbol.for("@effect-fc/ReactRuntime/ReactRuntime")
@@ -16,18 +14,9 @@ export interface ReactRuntime<R, ER> {
readonly context: React.Context<Context.Context<R>>
}
const ReactRuntimeProto = Object.freeze({ [ReactRuntimeTypeId]: ReactRuntimeTypeId } as const)
export const preludeLayer: Layer.Layer<
| Component.ScopeMap
| ErrorObserver.ErrorObserver
| QueryClient.QueryClient
> = Layer.mergeAll(
Component.ScopeMap.layer,
ErrorObserver.layer,
QueryClient.QueryClient.Default,
)
const ReactRuntimePrototype = Object.freeze({ [ReactRuntimeTypeId]: ReactRuntimeTypeId } as const)
export const preludeLayer: Layer.Layer<Component.ScopeMap> = Layer.mergeAll(Component.ScopeMap.layer)
export const isReactRuntime = (u: unknown): u is ReactRuntime<unknown, unknown> => Predicate.hasProperty(u, ReactRuntimeTypeId)
@@ -43,7 +32,7 @@ export const make = <R, ER>(
// biome-ignore lint/style/noNonNullAssertion: context initialization
context: React.createContext<Context.Context<R>>(null!),
}),
ReactRuntimeProto,
ReactRuntimePrototype,
)