Hi All,I would like to have a more capable version of the "if" condition so that I can write a "switch" like statement:div
h3 "Posts"
ul
- collection @posts
- if @type = "photo"
- view "photo_entry"
- if @type = "post"
- view "post_entry"
Just testing for "truthy" values of a model property is not sufficient. I have to preprocess the model property before generating the template by creating properties like: hasPhoto, hasPost, etc.Maybe introduce a statement like: - case @type = "photo"Is there a better way to do this?ThanksSanjay/Jonas
/Jonas