# Templating language questions

**URL:** <https://www.ruby-forum.com/t/templating-language-questions/168419>\
**Category:** Rails\
**Created:** [May 20, 2009, 5:33pm UTC](https://www.ruby-forum.com/t/templating-language-questions/168419 "2009-05-20T17:33:09Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Nicholas\_Faiz](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/n/35a633/32.png) [@Nicholas\_Faiz](https://www.ruby-forum.com/u/Nicholas_Faiz)\
**Post date:** [May 20, 2009, 5:33pm UTC](https://www.ruby-forum.com/t/templating-language-questions/168419/1 "2009-05-20T17:33:09Z")

</div>

Hello,

I’m experimenting with a xhtml templating language and have some  
questions about ActionPack, particularly to do with compilable  
templates. I’m mostly looking for further information about compilable  
templates.

The templating language currently works, though it isn’t a compilable  
template handler. I’ve yet to benchmark it, but it seems to be running  
quite fast (it’s built on nokogiri, which is fast).

I noticed that the erb and haml templating integrations are compilable -  
that is, they seem to return a string containing a representation of the  
template with ruby statements to be evaluated against the local scope;  
this string is stored as a method on  
ActionView::Base::CompiledTemplates. The code is in  
ActionView::Renderable. At any rate, my approach doesn’t do this at all

- it simply interprets the template, renders it, then passes it back.  
This is working very well for the prototype and I’m happy with it. I  
wanted to ask if anyone had experience in this area, though, and if it  
was a mistake to use a templating language which isn’t compilable in the  
ActionView::TemplateHandlers::Compilable sense?

The templating language is called Renshi, btw, and is loosely based on  
Python’s Genshi. It’s not ready for general use yet, but hopefully it  
will be presently.

[http://github.com/biv/renshi/tree/master](http://github.com/biv/renshi/tree/master)

Regards,  
Nicholas Faiz

---

<div class="post-metadata">

**Author:** ![Nicholas\_Faiz](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/n/35a633/32.png) [@Nicholas\_Faiz](https://www.ruby-forum.com/u/Nicholas_Faiz)\
**Post date:** [May 20, 2009, 5:42pm UTC](https://www.ruby-forum.com/t/templating-language-questions/168419/2 "2009-05-20T17:42:48Z")

</div>

Nicholas Faiz wrote:  
[…]

> The templating language is called Renshi, btw, and is loosely based on  
> Python’s Genshi. It’s not ready for general use yet, but hopefully it  
> will be presently.
> 
> [http://github.com/biv/renshi/tree/master](http://github.com/biv/renshi/tree/master)

Looks interesting. May I suggest that you investigate the Kwartz  
project? It’s got an almost identical template language, but with the  
added feature that data is kept out of the markup altogether.

> Regards,  
> Nicholas Faiz

## Best,

Marnen Laibow-Koser  
[http://www.marnen.org](http://www.marnen.org)  
removed\_email\_address@domain.invalid
