• Blog
  • Docs
  • Pricing
  • We’re hiring!
Log inSign up
project logo

aphoristicepigram

pillChoice

Starter template with client-side React & Hono server
Public
Like
pillChoice
Home
Code
7
.history
33
frontend
5
.vtignore
AGENTS.md
README.md
deno.json
H
index.ts
Branches
1
Pull requests
Remixes
History
Environment variables
1
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.
Sign up now
Code
/
.history
/
README_20251230180520.md
Code
/
.history
/
README_20251230180520.md
Search
…
Viewing readonly version of main branch: v102
View latest version
README_20251230180520.md

pillChoice

A tiny, shippable growth experiment built on Val Town.

This project is intentionally small: one email, two links, and a fully-instrumented mini web app. It demonstrates how I approach growth engineering at dev-tool companies—ship fast, measure everything, and wire feedback loops end-to-end.


What this is

pillChoice is a two-path experience inspired by the classic “choose your pill” metaphor:

  • Red pill → a public, role-tailored CV page + concrete growth ideas
  • Blue pill → a hidden route that triggers a server-side automation

Both paths log events to a shared SQLite database so behavior is observable immediately.


Why this exists

This was built as an application experiment for a Growth Engineer role at Val Town.

Rather than sending a traditional cover letter, I wanted to:

  • Build inside the platform
  • Show how I think about activation, instrumentation, and growth loops
  • Demonstrate comfort with Val Town’s execution model (Deno, Hono, stdlib)

How it works

Frontend

  • Single-page React app

  • No router library — routing is done via window.location.pathname

  • Client-side event tracking on:

    • page views
    • pill selection

Backend

  • Hono HTTP app (index.ts)
  • Val Town std/sqlite for persistence
  • Optional email + webhook triggers on the blue-pill route

Data

Events are stored in SQLite with:

  • timestamp
  • event type
  • pill choice (if applicable)
  • path
  • user-agent + referrer

You can inspect recent events at:

/api/events?limit=50

Routes

RouteDescription
/Landing page with pill choice
/redPublic CV + growth plan
/blueHidden route that triggers automation
/api/eventsJSON event log

Environment variables (optional)

These are not required, but enable extra proof points:

  • WEBHOOK_URL — POSTs a JSON payload when /blue is visited
  • NOTIFY_EMAIL_SUBJECT — subject line for notification email
  • NOTIFY_EMAIL_TO — recipient (if supported by plan)

Development workflow (Val Town)

There is no local dev server.

Instead:

vt watch # sync changes continuously vt browse # open the live site vt tail # view logs

The deployed site is the development environment.


Design principles

  • Minimal surface area — fewer moving parts, clearer intent
  • Observable by default — every meaningful action emits an event
  • Fast to iterate — new experiments should take minutes, not days

If you’re reading this

Thanks for taking the time 🙏

This project is small on purpose. The goal isn’t polish—it’s to show how quickly I can:

  • understand a platform
  • build within its constraints
  • and turn an idea into a measurable experiment

— Andy

FeaturesVersion controlCode intelligenceCLIMCP
Use cases
TeamsAI agentsSlackGTM
DocsShowcaseTemplatesNewestTrendingAPI examplesNPM packages
PricingNewsletterBlogAboutCareers
We’re hiring!
Brandhi@val.townStatus
X (Twitter)
Discord community
GitHub discussions
YouTube channel
Bluesky
Open Source Pledge
Terms of usePrivacy policyAbuse contact
© 2025 Val Town, Inc.