Safely evaluate JavaScript code.