From fdd10f7065b4d4b383ea0adaa8ddd95616dc5835 Mon Sep 17 00:00:00 2001 From: pjht Date: Tue, 8 Oct 2024 21:20:59 -0500 Subject: [PATCH] Display messages on the bottom of the message div --- frontend/src/main.rs | 6 +++--- prod.sh | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/frontend/src/main.rs b/frontend/src/main.rs index 024f371..93e8a18 100644 --- a/frontend/src/main.rs +++ b/frontend/src/main.rs @@ -123,11 +123,11 @@ impl Component for Home { }
- { self.messages.iter().map(|msg| html!{ -
+ { self.messages.iter().rev().map(|msg| html!{ +
{msg.message.clone()}
{msg.time.format("%I:%M:%S %p").to_string()}
} diff --git a/prod.sh b/prod.sh index 160af47..334aa19 100755 --- a/prod.sh +++ b/prod.sh @@ -6,4 +6,4 @@ pushd frontend trunk build popd -cargo run --bin server --release -- --port 8080 --static-dir ./dist +cargo run --bin server --release -- --port 8080 --addr :: --static-dir ./dist