Finally finish this enough to post

From here I will actually track changed with git but I just needed a base to work from.

RIP this attomic ass commit
This commit is contained in:
BuyMyMojo 2024-12-17 01:01:43 +11:00
parent 079e48c94e
commit 4bdb2ca436
Signed by: aria
GPG key ID: 19AB7AA462B8AB3B
48 changed files with 4693 additions and 657 deletions

View file

@ -0,0 +1,17 @@
import { useState } from 'preact/hooks';
export default function Greeting({messages}) {
const randomMessage = () => messages[(Math.floor(Math.random() * messages.length))];
const [greeting, setGreeting] = useState(messages[0]);
return (
<div>
<h3>{greeting}! Thank you for visiting!</h3>
<button class="greetButton px-2 rounded-xl" onClick={() => setGreeting(randomMessage())}>
New Greeting
</button>
</div>
);
}