Skip to main content
Module

x/fastro/pages/hello.tsx

Fast and simple web application framework for deno
Go to Latest
File
// deno-lint-ignore-file no-explicit-anyimport React, { useState } from "https://esm.sh/react@18.2.0";
const Hello = () => { const [link, setLink] = useState("Guest");
const handleChange = (e: any) => { setLink(e.target.value); };
return ( <div className="row align-items-center" style={{ height: "100vh" }}> <div className="mx-auto col-3"> <form className="row column-gap-2" action={`/${link}`} > <input className="form-control form-control-md col" type="text" placeholder="Hello guest" aria-label="Guest" onChange={handleChange} /> <button className="btn btn-primary col-2" style={{ width: "50px" }} type="submit" > Go </button> </form> </div> </div> );};
export default Hello;