diff --git a/deno.json b/deno.json index 0a36720..d5907e8 100644 --- a/deno.json +++ b/deno.json @@ -2,7 +2,9 @@ "lock": false, "tasks": { "start": "deno run -A --watch=static/,routes/ dev.ts", - "update": "deno run -A -r https://fresh.deno.dev/update ." + "update": "deno run -A -r https://fresh.deno.dev/update .", + "build": "deno run -A dev.ts build", + "preview": "deno run -A main.ts" }, "lint": { "rules": { @@ -10,7 +12,10 @@ "fresh", "recommended" ] - } + }, + "exclude": [ + "_fresh" + ] }, "imports": { "typesense": "https://raw.githubusercontent.com/bradenmacdonald/typesense-deno/main/mod.ts", @@ -22,10 +27,10 @@ "@islands": "./islands", "@islands/": "./islands/", "zod": "https://deno.land/x/zod@v3.21.4/mod.ts", - "$fresh/": "https://deno.land/x/fresh@1.3.1/", + "$fresh/": "https://deno.land/x/fresh@1.4.2/", "preact": "https://esm.sh/preact@10.15.1", "preact/": "https://esm.sh/preact@10.15.1/", - "preact-render-to-string": "https://esm.sh/*preact-render-to-string@6.2.0", + "preact-render-to-string": "https://esm.sh/*preact-render-to-string@6.2.1", "@preact/signals": "https://esm.sh/*@preact/signals@1.1.3", "@preact/signals-core": "https://esm.sh/*@preact/signals-core@1.2.3", "twind": "https://esm.sh/twind@0.16.19", @@ -35,5 +40,10 @@ "compilerOptions": { "jsx": "react-jsx", "jsxImportSource": "preact" + }, + "fmt": { + "exclude": [ + "_fresh" + ] } -} +} \ No newline at end of file diff --git a/fresh.gen.ts b/fresh.gen.ts index 93dc204..0409250 100644 --- a/fresh.gen.ts +++ b/fresh.gen.ts @@ -1,4 +1,4 @@ -// DO NOT EDIT. This file is generated by fresh. +// DO NOT EDIT. This file is generated by Fresh. // This file SHOULD be checked into source version control. // This file is automatically updated during development when running `dev.ts`. diff --git a/lib/env.ts b/lib/env.ts index f18ad01..a6777f7 100644 --- a/lib/env.ts +++ b/lib/env.ts @@ -21,4 +21,5 @@ export const TYPESENSE_URL = Deno.env.get("TYPESENSE_URL") || "http://localhost:8108"; export const TYPESENSE_API_KEY = Deno.env.get("TYPESENSE_API_KEY"); -export const LOG_LEVEL = Deno.env.get("LOG_LEVEL") || "warn"; +export const LOG_LEVEL: string = Deno.env.get("LOG_LEVEL") || + "warn"; diff --git a/routes/_app.tsx b/routes/_app.tsx index c980732..c7be36f 100644 --- a/routes/_app.tsx +++ b/routes/_app.tsx @@ -31,6 +31,8 @@ export default function App({ Component }: AppProps) { + + ")}}function Hr(){var e=K().querySelector('meta[name="htmx-config"]');if(e){return y(e.content)}else{return null}}function Lr(){var e=Hr();if(e){G.config=ne(G.config,e)}}Tr(function(){Lr();qr();var e=K().body;Nt(e);var t=K().querySelectorAll("[hx-trigger='restored'],[data-hx-trigger='restored']");e.addEventListener("htmx:abort",function(e){var t=e.target;var r=ee(t);if(r&&r.xhr){r.xhr.abort()}});var r=window.onpopstate;window.onpopstate=function(e){if(e.state&&e.state.htmx){zt();te(t,function(e){oe(e,"htmx:restored",{document:K(),triggerEvent:oe})})}else{if(r){r(e)}}};setTimeout(function(){oe(e,"htmx:load",{});e=null},0)});return G}()}); \ No newline at end of file