scoped is also a library that will give you all of the scope information about
falafel-generated AST! (it even works with
var scoped =falafel =// you can also tell scoped to ignore certain globals:
it notifies you of globals -- both explicit (created by assigning) and implicit (use without definition) -- and, when given a position in the file, will let you know what variables are in scope at that point.
outputs only global usage/leakage information, with line and column numbers.
outputs scope chain, with usage/definition for each scope.
in the form
,COLUMN may be omitted, if so, it is assumed
column are assumed to be 1-indexed (like most
+ signs indicate scope definitions -- i.e., a new variable was created
in this scope.
* signs indicate use of a variable from a containing scope.
If the function is named, it will use that to describe the function.
npm install -g scoped