Email preview server: live URL for MJML design iteration #305
Labels
No labels
domain:backend
domain:devops
domain:frontend
status:approved
status:in-progress
status:needs-fix
status:qa
type:bug
type:devops
type:feature
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
forgejo_admin/basketball-api#305
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Type
Feature
Lineage
Standalone — discovered during email design session (2026-04-03). Can't iterate on email design without seeing results live.
Repo
forgejo_admin/basketball-apiUser Story
As an admin,
I want a live preview URL that updates when email templates change,
So that I can approve email designs on my phone without deploying to production.
Context
MJML templates compile to HTML. Currently the only way to see an email is to deploy and send a test. Design iteration needs a faster loop: agent edits MJML → compiles → preview URL updates → Lucas checks phone.
The preview server is a dev tool, not a production service. It runs locally on archbox and gets a Tailscale funnel URL.
Solution
A simple npm script that:
templates/email/*.mjmlfor changestemplates/email/compiled/on save (mjml --watch)templates/email/compiled/on a local port (e.g. npx serve or python3 -m http.server)Add to package.json:
Or simpler: two terminal commands, no new dependency.
File Targets
Files to modify:
package.json— addpreview:emailscriptFiles NOT to touch:
Acceptance Criteria
npm run preview:emailstarts watcher + serverhttp://localhost:3001/action.htmlshows the compiled templatetailscale funnel 3001makes it accessible on phoneTest Expectations
Constraints
Checklist
Related
arch-email— email architectureproject-westside-basketball— parent project