vtTokenSessionAuth
Val Town is a collaborative website to build and scale JavaScript apps.
Deploy APIs, crons, & store data – all from the browser, and deployed in milliseconds.
Viewing readonly version of main branch: v2View latest version
Protect your vals behind your Val Town API Token. Use session cookies to persist authentication.
Forked from @pomdtr/password_auth.
import { vtTokenSessionAuth } from "https://esm.town/v/stevekrouse/vtTokenSessionAuthSafe";
export default vtTokenSessionAuth(() => Response.json("Authenticated!"))
To sign out, navigate to /signout
.
Migrated from folder: Archive/vtTokenSessionAuth