pomdtr avatar
apricotPartridge
@pomdtr
HTTP
// use my private proxy
pomdtr avatar
lastloginExample
@pomdtr
HTTP
An interactive, runnable TypeScript val by pomdtr
pomdtr avatar
lastloginHono
@pomdtr
Script
See @pomdtr/lastlogin for more informations about the middleware Example /** @jsxImportSource npm:hono@3/jsx */ import { lastlogin } from "https://esm.town/v/pomdtr/lastloginHono"; import { Hono } from "npm:hono"; const app = new Hono(); const lastloginMiddleware = lastlogin({ allowSignup: true, }); // required for the auth pages to work app.use("/auth/*", lastloginMiddleware); // this page is public app.get("/", async (c) => { return c.html( <div> There is a secret message for you if you{" "}<a href="/secret">login</a> </div>, ); }); // this page requires the user to signup app.get("/secret", lastloginMiddleware, async (c) => { const email = c.req.header("X-User-Email"); return c.html( <div> I think {email} is a really silly email address, actually. </div>, ); }); export default app.fetch;
pomdtr avatar
libsqlstudio
@pomdtr
HTTP
LibSQLStudio To authenticate, use an API Token .
pomdtr avatar
handler
@pomdtr
Script
An interactive, runnable TypeScript val by pomdtr
stevekrouse avatar
libsqlstudio
@stevekrouse
HTTP
LibSQLStudio I'll write down the instructions tomorrow. The short version is: fork the val create the email env var, with your own email.
iamseeley avatar
libsqlstudio
@iamseeley
HTTP
An interactive, runnable TypeScript val by iamseeley
pomdtr avatar
sapphireSeahorse
@pomdtr
HTTP
An interactive, runnable TypeScript val by pomdtr
sqlite avatar
libsqlstudio
@sqlite
HTTP
LibSQLStudio I'll write down the instructions tomorrow. The short version is: fork the val create the email env var, with your own email.
1
Next
v96
June 19, 2024