Hacker News new | comments | show | ask | jobs | submit login

Build an HTML generator of function PreHtml -> HTML that is quirk compatible with all browsers. Yes, you will has many bugs to fix over time. Now have all your templates code emit output of type PreHtml and your final page generation phase is the function above.

Pay attention here: any template that attempts to emit HTML will fail to Typecheck.

Not a panacea, but static enforcement of Don't Repeat Your Bugs, even before those particular bugs are discovered.

Guidelines | FAQ | Support | API | Security | Lists | Bookmarklet | DMCA | Apply to YC | Contact