window-eval
Advanced tools
Comparing version 0.0.6 to 0.0.7
@@ -20,4 +20,4 @@ function windowEval(code, context = {}, options = {}) { | ||
} | ||
return eval(`with (proxy) {${code}} | ||
//# sourceURL=${options.filename}`); | ||
return new Function('proxy', `with (proxy) {${code}} | ||
//# sourceURL=${options.filename}`).call(proxy, proxy); | ||
} | ||
@@ -24,0 +24,0 @@ windowEval.builtinKeys = [ |
{ | ||
"name": "window-eval", | ||
"version": "0.0.6", | ||
"version": "0.0.7", | ||
"description": "Eval in context (global/window), in pure JS", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
2021