sstephenson/ruby-ejs — pull request #14 by wireframe (2013-02-20 16:02:50+00:00)
Title: add EJS.variable_name to mirror Underscore template variable option

Underscore's _.template method supports a `variable` option to allow for templates to use the defined variable name instead of local scope.
http://underscorejs.org/#template

This branch ports existing Underscore behavior to EJS by adding the `EJS.variable_name` option.

One nice side effect of this change is that rendering no longer uses the Javascript `with` statement which is slow and should generally be avoided whenever possible.

Resources:
http://jsperf.com/with-statement/4
http://www.yuiblog.com/blog/2006/04/11/with-statement-considered-harmful/