From 35374e9d1950346f5935411d96fa3fa46afd41a0 Mon Sep 17 00:00:00 2001 From: EccentricVamp Date: Sat, 19 Nov 2022 16:52:18 -0600 Subject: [PATCH] Fix hydration again --- main.ts | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/main.ts b/main.ts index ab79655..7c4704d 100644 --- a/main.ts +++ b/main.ts @@ -1,9 +1,9 @@ -import { getSheet } from "twind"; +import { dom } from "twind"; import { FreshwindUserConfig, setup, STYLE_ELEMENT_ID } from "./shared.ts"; export default function hydrate(options: FreshwindUserConfig) { - const sheet = getSheet(true, false); - // @ts-ignore Remove this once Twind plays nice with islands - sheet.target = document.getElementById(STYLE_ELEMENT_ID) as HTMLStyleElement; + const sheet = dom( + document.getElementById(STYLE_ELEMENT_ID) as HTMLStyleElement, + ); setup(options, sheet); }