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

feat(commands): Go to Source Definition #384

Merged
merged 1 commit into from
Jul 29, 2022

Conversation

fannheyward
Copy link
Member

@fannheyward fannheyward commented Jun 30, 2022

tsserver.goToSourceDefinition, close #383

@sandrodz
Copy link

This is awesome, hopefully it gets in soon.

@chemzqm chemzqm merged commit 8430908 into neoclide:master Jul 29, 2022
@sandrodz
Copy link

sandrodz commented Jul 29, 2022

@fannheyward how do we make this work with vim's gd (for TS only)?

My current bindings are

" Remap keys for gotos
nmap <silent> gd <Plug>(coc-definition)
nmap <silent> gy <Plug>(coc-type-definition)
nmap <silent> gi <Plug>(coc-implementation)
nmap <silent> gr <Plug>(coc-references)

@chemzqm
Copy link
Member

chemzqm commented Jul 29, 2022

You can create buffer key-mappings :h map-buffer

@powext
Copy link

powext commented Sep 1, 2022

Hi! Vim noob here, I've some difficulties trying to map this command 😅

EDIT: resolved with nmap <silent> gd :CocCommand tsserver.goToSourceDefinition<CR>

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.

Support new "Go to Source Definition" feature in TS 4.7
4 participants