slime-lang / slime

Minimalistic HTML templates for Elixir, inspired by Slim.
http://slime-lang.com
MIT License
371 stars 57 forks source link

Render tag attributes depending on runtime variable value #36

Closed Rakoth closed 9 years ago

Rakoth commented 9 years ago

Resolve #34 @doomspork I am thinking of some thing like this to resolve issue with attribute value. I is not possible to evaluate all values at compile time, because we can call template with different variables in runtime.

Rakoth commented 9 years ago

We can use (fun -> ... end).() wrapping to not create any variables in template context

doomspork commented 9 years ago

@Rakoth this looks good to me, thanks for knocking this one out. I'm good to merge this if you are.

Rakoth commented 9 years ago

@doomspork go ahead :ship: