microsoft / microsoft/vscode-js-debug

Support evaluateName for all variable references

Open
#1,924 0 comments 0 reactions 1 assignee View on GitHub

@connor4312 is already working on this.

Since Jan 24, 2024.

feature-request
Dominant language
TypeScript
Stars
2k
Forks
373
Avg merge
1d 9m
Merged PRs (30d)
6

Description

Sometimes, there can be anonymous variable references, like this:

image

It would be nice if these variable references also have an evaluateName that can act as a js variable name for evaluate calls.

This evaluateName should be safe to use in expression, e.g. myFunction(${myVar.evaluateName}).
This means, before evaluating expressions, these evaluateNames have to be pre-processed.
If you use replaceAll, make sure the evaluateName is long enough (256 bits should be fine) to avoid any accidental replacements.

To be consistent, the evaluateName only works for the given frame id, so you cannot mix variables from different frame ids in one expression.

CDP has these things that might be helpful:

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.