Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issues with Anonymous Functions, Const Declarations, and Class Inheritance in TS/JS #30

Open
mxyhi opened this issue Apr 1, 2024 · 1 comment

Comments

@mxyhi
Copy link

mxyhi commented Apr 1, 2024

In TypeScript/JavaScript, anonymous functions don't work, and the same goes for functions declared with 'const'. Also, class extension ('extends') inheriting methods from a base class doesn't work.
image
image
👇But the following code snippet below fails to be recognized correctly.
image

@chanhx
Copy link
Owner

chanhx commented Apr 1, 2024

Currently, Crabviz analyzes calling relationships of three kinds of symbols: function, method, and constructor. And anonymous functions in JS/TS are marked as variables (You can check symbol kinds in the outline panel), which are filtered out, so you don't see them in the call graph.

Analyzing calling relationships of variables makes no sense in most cases, but I think we can do it in some cases for some languages, will try it later.

class extension ('extends') inheriting methods from a base class doesn't work.

I don't quite get it, could you provide some examples or explanations?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants