1

CPAN has the Template::Declare package. A declarative way to create HTML templates in Perl without any HTML directly written.

I would love to use similar packages in python and ruby. Are there equivalent packages for those languages?

matthias krull
  • 4,389
  • 3
  • 34
  • 54

3 Answers3

6

In Ruby there is Markaby. The closest I know if in Python is Brevé.

Also there are a few more in Perl and other languages as well.

/I3az/

Community
  • 1
  • 1
draegtun
  • 22,441
  • 5
  • 48
  • 71
1

If you like the look of Markaby, also see Erector which is inspired by it but said to be somewhat cleaner

telent
  • 1,813
  • 15
  • 21
0

Are you looking for something like Haml in Ruby ?

Example for Ruby :

$ sudo gem install haml
$ irb
> require 'haml'
> Haml::Engine.new('%p Hello, World').render
=> "<p>Hello, World</p>\n"
David
  • 998
  • 7
  • 17
  • I know haml but it is still a different language. I would like ruby templating in ruby code and python templating in python code. – matthias krull Aug 31 '10 at 12:15