Visit homepage

Building an email-based course creator with Val Town

  • Planted:

This Show ’n tell is a "Seedling", which means I still have lots of writing to do. I’ll tend to it as I complete the course tool and wrap up my first course. More on that below...

I recently read Make It Stick, a book written by cognitive psychologists about effective learning techniques, backed by research. One of the topics covered is spaced repetition, which I started practicing in my own learning this summer using flashcard software Anki.

While reading, I was reminded of Just JavaScript, which I took in 2021 as an email-based course in beta before its full launch as a web application (amazing course btw, for anyone who wants to strengthen their JavaScript mental models). An email-based course means you receive lessons or chapters as emails rather than in a PDF or website.

Just JavaScript was programmed so that when you submitted the quiz at the end of each lesson you’d receive the next one. But what if instead of receiving the next lesson immediately you had to wait a day? Spaced repetition is key to learning, and email can be a useful medium to naturally bake in time between lessons.

Email-based course creator

With all that in mind, I am making an email-based course creator using that anyone who knows some JavaScript and HTML can fork to create their own email-based course. Along with spaced repetition, I lean on other effective learning techniques from the book to inform course structure:

  • Fill-in-the-blank before each lesson as generation
  • Mixing up order of content as interleaving
  • Quizzing as retrieval practice
  • Free form writing at the end of each lesson as elaboration and reflection

As an example (and hopefully a useful resource), I’m using the course creator to write a course about learning techniques and research covered in Make It Stick. And if you’re interested in Val Town, I also wrote about creating a global button and managing email subscribers.

Signing up

For signup and email verification, I forked a Hono router Val that I wrote for subscribers (signup for that is in the footer). See the Val Town iframe below. I added a root endpoint / that returns a signup form for the course, which you can test out in the "Browser preview" at the bottom of the iframe. I also set up a landing page for the course that hits the /send-verification endpoint. I cover signup and verfication in more detail in my Show ’n Tell on cultivating emails.

To be written

I’ll add code examples and descriptions for storing subscribers with SQLite, sending lessons via email with a cron, handling unsubscribe, emailing student responses, and more. In the meantime, feel free to reach out with any comments, questions, or feedback.



Respond with your thoughts, feedback, corrections, or anything else you’d like to share. Leave your email if you’d like a reply. Thanks for reading.