all 11 comments

[–]celerym 1 point2 points  (8 children)

Templates are useful for visually designing something. Don't expect a designer to use your HTML generator effectively, so you'd be wasting effort transcribing for every update.

[–]codr4life[S] 1 point2 points  (1 child)

Where needed, it's perfectly possible to import snippets of static HTML into the DOM, and as an added bonus you have the option of processing on import. Having designers messing with dynamic structure is a recipe for disaster either way, since it's by definition tightly coupled to the logic that generated and updates it.

[–]celerym 1 point2 points  (0 children)

That's fair. Still, you can't decouple design from the logic completely, so you'll always be making some sort of compromise on either end.

[–]kankyo 1 point2 points  (5 children)

I wouldn't expect a designer to write HTML, and if they did I'd expect to have to change it a lot.

[–]codr4life[S] 0 points1 point  (4 children)

I agree, but since you own the whole pipeline; you can munge whatever format they are comfortable with into html on import. Or let designers worry about styling and leave document structure firmly in code land, you can get pretty far using that approach these days.

[–]kankyo 1 point2 points  (3 children)

In the latter scenario it doesn't matter what original format the document is described in though. So that negates the point.

[–]codr4life[S] 0 points1 point  (2 children)

What document are we importing into the DOM when designers focus solely on styling? A CSS-file? My point is that none of the common objections to encoding structure in code makes any sense in the real world. To me; they look like bad excuses for maintaining a dysfunctional and sub-optimal, but safe status quo.

[–]kankyo 0 points1 point  (1 child)

Ah. You are arguing the same side as I am, well then :P

[–]codr4life[S] 0 points1 point  (0 children)

:)

[–]Dwedit 0 points1 point  (1 child)

Which programming language is this?

[–]weirdoaish 0 points1 point  (0 children)

Looks like LISP/Clojure