From 57cea355fea6f63f05400e350d18d8e4077674ca Mon Sep 17 00:00:00 2001 From: EthanThatOneKid <31261035+EthanThatOneKid@users.noreply.github.com> Date: Sat, 6 Apr 2024 13:57:19 -0700 Subject: [PATCH] add the htx library --- cli/main.tsx | 18 ++++++++++++++++-- deno.json | 1 + 2 files changed, 17 insertions(+), 2 deletions(-) diff --git a/cli/main.tsx b/cli/main.tsx index 8741f1b..f4837ab 100644 --- a/cli/main.tsx +++ b/cli/main.tsx @@ -1,5 +1,5 @@ -import { Delete } from "@fartlabs/rtx"; -import { Get, Post, Router } from "@fartlabs/rtx"; +import { Delete, Get, Post, Router } from "@fartlabs/rtx"; +import { A, BODY, H1, P } from "@fartlabs/htx"; import { go } from "go/go.ts"; type Shortlinks = Record; @@ -91,6 +91,20 @@ if (import.meta.main) { return Response.json({ message: "Shortlink deleted." }); }} /> + { + return new Response( + +

+ go.fart.tools +

+

Welcome!

+ , + { headers: { "Content-Type": "text/html" } }, + ); + }} + /> { diff --git a/deno.json b/deno.json index 27bfb18..75457a6 100644 --- a/deno.json +++ b/deno.json @@ -1,6 +1,7 @@ { "lock": false, "imports": { + "@fartlabs/htx": "jsr:@fartlabs/htx@^0.0.1", "@fartlabs/jsonx": "jsr:@fartlabs/jsonx@^0.0.10", "@fartlabs/rtx": "jsr:@fartlabs/rtx@^0.0.2", "@std/assert": "jsr:@std/assert@^0.221.0",