Hacker News new | ask | show | jobs
by dmpayton 4577 days ago
It's more to do with separation of concerns. The presentation of data should be the responsibility of the front-end (in this case, the data is a form description and the front-end is in your web browser).

This is very useful for when you have a single API that drives your web, Android, and iOS apps. Your back-end just describes the form in JSON and each front-end is responsible for how that form renders. Alpaca is just a shortcut for your web front-end.

2 comments

You get the irony though that this was the original purpose of SGML (which admittedly HTML 1.0 thoroughly screwed up). It seems perfectly reasonable to render the page using HTML and have the render logic for browsers or what have you be in the form of style sheets and Javascript.
You hit the nail on the head. We use a system like that and it is fantastic. As close to DRY as you can get.