[Rails] rubyonrails w/ amrita

Corey corey_s at qwest.net
Wed Oct 13 06:13:31 GMT 2004


On Wednesday 13 October 2004 10:30 am, Tobias Luetke wrote:
<snip>
> > I have to imagine  there are at least a few instances where amrita's
> > clear separation of logic from presentation would be beneficial. 
<snip>
>
> Well well, while i respect your preference for another templating
> engine I would like to point out  that you are trying to seperate your 
> view from your application with a  straw as datapipe. I'm pretty sure
> most web programmers have been in the situation where they 
> discovered  that they separated things so much that it was inconvenient.
>

Definitely. 

There certainly are pros and cons with each approach.


> Ruby is the best scripting language out there, with erb you can use it
> inline in templates. This is equivalent with what the best dedicated
> template engine will offer you: total control over your data.
>

I"m extremely impressed with ruby - I've ditched perl, and I'm likely going
to decide against python/zope3 since discovering rubyonrails. 


> I suggest you to give erb a try. If you don't like the way tags are
> opened you can change this to whatever style you see fit.
>
> I'm programming an e-commerce site in ruby on rails and there isn't a
> single rhtml template file which has a erb statement longer than one line.
> Just in case you think that  using erb leads to programming in the
> templates. 
>

It's true that with discipline and skill, one can largely avoid making a
huge mess out of the templates.  Like most things, it often comes 
down to a simple matter of personal preference or habit - though
there are cases in which having a choice is beneficial: depending on 
the specifics of a project, a particular templating engine can provide
a more natural fit.


Beers!

Corey

-- 

"Government begins by protecting some against others and ends up
protecting itself against everyone."
  - Robert LeFevre



More information about the Rails mailing list