4 ms·
I think there are some errors in the final solution code, as it doesn't do what you describe. Were you aiming at something like this? var generated = function
by sigilworks 13y ago
I think there are some errors in the final solution code, as it doesn't do what you describe.
Were you aiming at something like this?
var generated = function(value) {
return new Function( "return (" +
function(valueToSwap) { return { prop: valueToSwap }; }
+ ")(" + value + ");" );
};