Skip to main content
Ben Nadel
On User Experience (UX) Design, JavaScript, ColdFusion, Node.js, Life, and Love.

eval is evil

Member since May 5, 2010

Recent Blog Comments By eval is evil

  • Javascript Function() Constructor Does Not Create A Closure

    Posted on May 5, 2010 at 5:36 AM

    In my opinion if you are using new Function your missing the power of closures. However if you really need this try function(){eval("...")} var foo = "win"; (function(){ var foo = "fun"; (function(){eval("console.log('eval: ' + foo)")})(); (new Function("console.log('Func: ' + foo)"))(); (f... read more »