Skip to content

Add getDefinitionAndBoundSpan #20

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

Merged
merged 1 commit into from
Apr 19, 2022

Conversation

yesmeck
Copy link
Contributor

@yesmeck yesmeck commented Apr 19, 2022

Hi, I'm writing a plugin that implements Go to Definition to a file within a template literal that needs getDefinitionAndBoundSpan .

@ghost
Copy link

ghost commented Apr 19, 2022

CLA assistant check
All CLA requirements met.

assert.strictEqual(definitions.length, 1);
const [def] = definitions;
assert.deepEqual(def, { "file": mockFileName, "start": { "line": 1, "offset": 6 }, "end": { "line": 1, "offset": 11 } });
assert.deepEqual(textSpan, { "start": { "line": 1, "offset": 6 }, "end": { "line": 1, "offset": 10 } });
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not sure if it's correct that this end offset is different from the one above.

@mjbvz mjbvz merged commit dc429e5 into microsoft:main Apr 19, 2022
@mjbvz
Copy link
Contributor

mjbvz commented Apr 19, 2022

Thanks! Will publish new version shortly

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

Successfully merging this pull request may close these issues.

2 participants