1
2
3
4
5
6
7
// View at https://stevekrouse-expressHTMLExample.express.val.run?name=Steve
export async function expressHTMLExample(
req: express.Request,
res: express.Response,
) {
return res.send(`<h1>Hi ${req.query.name || req.body.name}!</h1>`);
}
Only the latest version can be previewed
👆 This is a val. Vals are TypeScript snippets of code, written in the browser and run on our servers. Create scheduled functions, email yourself, and persist small pieces of data — all from the browser.