Skip to content

Instantly share code, notes, and snippets.

@indutny indutny/gist:703211
Created Nov 17, 2010

What would you like to do?
Node.js runInNewContext problem
var vm = require('vm');
var pseudo_array = vm.runInNewContext('[]');
console.log(pseudo_array instanceof Array); // Voila! "false"

This comment has been minimized.

Copy link

shimondoodkin commented Dec 28, 2010

lol + like


This comment has been minimized.

Copy link
Owner Author

indutny commented Dec 29, 2010

Actually, you can check this using Array.isArray(...)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.