Skip to content
This repository has been archived by the owner on Oct 21, 2024. It is now read-only.

Commit

Permalink
fix refresh loop issue 🐛 (#4)
Browse files Browse the repository at this point in the history
  • Loading branch information
Freymaurer committed Dec 15, 2022
1 parent 0a66086 commit 5b69edf
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions client/generators/layout.fsx
Original file line number Diff line number Diff line change
Expand Up @@ -106,10 +106,11 @@ open Docsloader
open Fornax

let render (ctx : SiteContents) cnt =
let disableLiveRefresh = ctx.TryGetValue<DocsConfig> () |> Option.map (fun n -> n.disableLiveRefresh) |> Option.defaultValue false
cnt
|> HtmlElement.ToString
|> fun n -> if disableLiveRefresh then n else injectWebsocketCode n
#if WATCH
|> injectWebsocketCode
#endif

let docsLayout (docs: Nfdi4Plants.Docs) =
// just an example url
Expand Down

0 comments on commit 5b69edf

Please sign in to comment.