Val Town Newsletter 13
It’s been almost three months since the last Val Town Newsletter in early Sept! We went into a deep engineering hole to build Val Town v3. It shipped on Oct 23rd.
We then immediately embarked upon a cycle of user interviews and product polish, which has resulted in dozens of new features in the past couple weeks. We created the concept of Val Types: HTTP Handler, Interval, Email Handler, or a Script. We launched Val Town Blob and SQLite storage to put powerful persistence at your fingertips. Val exports and names are much easier to work with now too.
Coming up soon are “pull requests” for vals, continuing to polish and clarify the UI, moving our docs site to a public Github repo, custom domains, public folders, and much more!
Vals are being used on everything from tracking prices and RSS feeds to categorizing help tickets to making geolocation APIs. Lots of fun links below!
If you would like to do us a big favor, please email steve@val.town to schedule a user interview and onboarding session. The feedback we get from these sessions are what enable us to improve Val Town. We’re most excited to chat with folks at businesses who want to automate processes, make webhooks, little APIs, or crons. However, we’re happy to chat with anyone – please reach out!
Val Town v3
Val Town v3 finally shipped on October 23rd. It removed our custom @
symbol syntax, but kept the ability to import code by typing the @
symbol: we rewrite it as a web-standard JS import when you accept the completion. It’s more stable, easier to learn, supports JSX, environment variables, has no vendor lock-in, and fixed dozens of other bugs. It’s just way better — try it out!
Val Types
We created the concept of Val Types: HTTP Handler, Interval, Email Handler, or a Script. This lets us specialize the UI particularly for each type of val, which we’ve only just begun taking advantage of.
SQLite & Blob Storage
We all know functions are most useful when they can persist some state. Up until now, we had two bad answers:
- Store your state in JSON in another val
- Go signup for a database and come back here with your keys
The problem with (1) was that it only stored 100kb and it wasn’t ACID. The problem with (2) was that it took you out of the flow of programming.
A couple weeks ago we launched two integrations that let you persist real data without leaving Val Town:
Val Town SQLite gives you your own SQLite database. There is no setup. Just start writing SQL. Make tables, insert data, run queries, whatever you want!
Val Town Blob lets you store any sort of unstructured data, like JSON, text, images, binary, whatever. Again, no setup, buckets, regions, or keys. Just send us your blobs, and then retrieve your blobs.
Exports & names
Vals used to require exactly one export, and the name of that export was the name of the val. This was confusing to users, so we moved the name of vals outside the code, and allow vals to have as many or few exports as you’d like.
Roadmap
- Docs site in a public github repo
- Near-at-hand templates for common patterns, like importing from npm, using secrets, JSX, emailing yourself, persistence, OpenAI…
- Clearer UI for running vals & logs (more intuitive feedback loop)
- Lots of small upgrades and polish to product, docs, onboarding
- Pull requests for vals
- Public folders
- Custom domains
- Benchmark v3 runtime performance and update limits
- LLM to help you write vals
Links
- Posthog shows how to use Val Town to capture RSS events in Posthog
- Val Town is being taught in a Northeastern class!
- Pete Millspaugh wrote fantastic blogs, making a counter button, and collecting subscriber email addresses
- Nage Eagle wrote a lovely blog about his cron to scrape HTML to find when Sea Light Swizzles were back in stock
- whatrocks showed us how he extended the Farcaster protocol to create a distributed
finger
solution. A fantastic read! - Tom open-sourced Val Town’s CodeMirror + TypeScript integration
- Andre made the best video with vals ever made (to help him work out)
- xkonti made an incredible ntfy val to send yourself push notifications on your phone
- Justin Bennett made vals to get your sleep and readiness from your oaura ring
- tal made an iCal feed that updates with Department of Education (lunch) menu items
- fil made a val to check when his favourite museum activities are updated
- maxm made this awesome retro-style visit counter
- Guy Dupont generated STL files with a val
- Steve made a handy val to make sure he never forgets an umbrella and another to help help him know how warm to dress
- tmcw showed us how we could use Elysia, the speedy new Bun web server library, in Val Town
- wilt showed off the new Windows feature allowing you to add PWAs to your dock
- jamiedubs created a val to fetch an image from any smart contract
- Generate a powerpoint from a val