A JavaScript AST scope analyzer. The module is heavily inspired by escope.
$ npm install ast-scope
var esprima = require('esprima');
var as = require('ast-scope');
var ast = esprima.parse('var foo = function() {};');
var topScope = as.analyze(ast);
MIT