3

This is a very old question, but most answers from 2009 are outdated. As e.g. How to generate call-graphs for given javascript?

Using Google, I also found on npm this module https://www.npmjs.com/package/callgraph but it's not maintained and doesn't work.

So, I'm bringing this after a couple of years up again to see if anyone has created something to make a simple call graph based on a js file or a code snippet?


Edit:

Well after couple of months, I still havn't found anything. The closest i came was this JS Code to SVG Flowchart

Advena
  • 1,664
  • 2
  • 24
  • 45

1 Answers1

1

I wasn't able to get callgraph from NPM to work either, but I've been having better luck with js-callgraph, which was updated this year (2019). It doesn't generate visual output, but you'll get a JSON data structure that can be piped into other graphing tools like Gephi or Graphviz.

https://github.com/Persper/js-callgraph

Cameron Yick
  • 708
  • 1
  • 8
  • 16