class Crustache::Engine

Defined in:

crustache/engine.cr

Constructors

Instance Method Summary

Constructor Detail

def self.new(fs : FileSystem) #

[View source]
def self.new(basedir, cache = false) #

[View source]

Instance Method Detail

def render(filename : String, model, io) #

[View source]
def render(tmpl, model, io) #

[View source]
def render(filename : String, model) #

It renders a template loaded from filename with model and it returns rendered string. If filename is not found, it returns nil, but it dosen't raise an error.


[View source]
def render(tmpl, model) #

[View source]
def render!(filename : String, model, io) #

[View source]
def render!(filename : String, model) #

It is a strict version Engine#render. If filename is not found, it raise an error.


[View source]