Web lists-archives.com

Bug#854510: ITP: node-astw -- walk the ast with references to parent nodes




Package: wnpp
Severity: wishlist
Owner: Shirish Togarla <shirishtogarla533@xxxxxxxxx>
X-Debbugs-CC: debian-devel@xxxxxxxxxxxxxxxx

* Package name    : node-astw
  Version         : 2.0.0
  Upstream Author : James Halliday <mail@xxxxxxxxxxxx> (http://substack.net)
* URL             : https://github.com/substack/astw
* License         : Expat
  Programming Lang: _javascript_
  Description     : walk the ast with references to parent nodes

 This module is a faster version of
 [falafel](https://github.com/substack/node-falafel)
 that only does ast walking and `.parent` tracking, not source transforms.
 # example
 var astw = require('astw');
 var deparse = require('escodegen').generate;
 var walk = astw('4 + beep(5 * 2)');
 walk(function (node) {
    var src = "">    console.log(node.type + ' :: ' + JSON.stringify(src));
 });