Skip to content

mansoor935/python-eco

 
 

Repository files navigation

Python Eco

Python Eco is a bridge to the Eco (CoffeeScript Template) Compiler.

import eco

eco.compile(open("template.eco"))
# Out: u"function(...) {...}"

context = eco.context_for("Hello <%= @name %>")
context.call("render", {"name": "Sam"})
# Out: u'Hello Sam'

eco.render("Hello <%= @name %>", name="world")
# Out: u'Hello world'

Setup

$ pip install eco

License

MIT License

Packages

No packages published

Languages

  • Python 100.0%