Javascript – eval vs Function() return semantics
Disclaimer: The code mentioned in the question is assumed to be running in the trusted environment (not the browser), and the code itself is trusted. So any security considerations about eval are not applicable. The main goal of the question…