Runtime refactoring
All checks were successful
Lint / lint (push) Successful in 11s

This commit is contained in:
Julien Valverdé
2025-08-21 01:57:53 +02:00
parent 37e4a5720f
commit 925a3d1264
5 changed files with 70 additions and 53 deletions

View File

@@ -1,5 +1,5 @@
import { createRouter, RouterProvider } from "@tanstack/react-router"
import { ReactManagedRuntime } from "effect-fc"
import { ReactRuntime } from "effect-fc"
import { StrictMode } from "react"
import { createRoot } from "react-dom/client"
import { routeTree } from "./routeTree.gen"
@@ -16,8 +16,8 @@ declare module "@tanstack/react-router" {
createRoot(document.getElementById("root")!).render(
<StrictMode>
<ReactManagedRuntime.Provider runtime={runtime}>
<ReactRuntime.Provider runtime={runtime}>
<RouterProvider router={router} />
</ReactManagedRuntime.Provider>
</ReactRuntime.Provider>
</StrictMode>
)

View File

@@ -1,7 +1,7 @@
import { FetchHttpClient } from "@effect/platform"
import { Clipboard, Geolocation, Permissions } from "@effect/platform-browser"
import { DateTime, Layer } from "effect"
import { ReactManagedRuntime } from "effect-fc"
import { ReactRuntime } from "effect-fc"
export const AppLive = Layer.empty.pipe(
@@ -12,4 +12,4 @@ export const AppLive = Layer.empty.pipe(
Layer.provideMerge(FetchHttpClient.layer),
)
export const runtime = ReactManagedRuntime.make(AppLive)
export const runtime = ReactRuntime.make(AppLive)