Skip to content

Commit

Permalink
Update docs
Browse files Browse the repository at this point in the history
  • Loading branch information
albertwoo committed Nov 19, 2024
1 parent d51853c commit 21e9bdf
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions Fun.Blazor.Docs.Server/HtmxDemo.fs
Original file line number Diff line number Diff line change
Expand Up @@ -10,16 +10,17 @@ type HtmxSseStockDemo() =
inherit HxSseComponent()

override _.GetNodes() = taskSeq {
for i in 1..5 do
for productId in 1..5 do
div {
"stock: "
MudChip'' {
Variant Variant.Filled
Color(if i % 2 = 0 then Color.Primary else Color.Secondary)
Color(if productId % 2 = 0 then Color.Primary else Color.Secondary)
"Product #"
i
productId
": "
System.Random.Shared.Next(100, 200)
"$"
}
}
do! Async.Sleep 1000
Expand All @@ -40,8 +41,8 @@ type HtmxDemo =
section {
hxSseConnectComp (QueryBuilder<HtmxSseStockDemo>())
hxSseCloseOnComp
hxSseSwapOnComp
"Htmx SSE demo with attributes:supposed to display the latest stock info"
"Htmx SSE demo: supposed to display the latest stock info"
div { hxSseSwapOnComp }
}
MudDivider'' { style { margin 20 0 } }
section {
Expand Down

0 comments on commit 21e9bdf

Please sign in to comment.