Giter Club home page Giter Club logo

Comments (2)

wookayin avatar wookayin commented on August 13, 2024

Hello, thanks for your interest and using my dotfiles.

I see that gt and gT keys are mapped (when LSP is enabled) to LSP type definitions: https://github.com/wookayin/dotfiles/blob/master/nvim/lua/config/lsp.lua#L61

In vim, you can check the keymappings using:

:map gt

or

:Maps

followed by some keyword. Such mapping has existed since July 2022. When the buffer does not have any language server client attached (E.g. on Nerdtree or some other normal buffers), gt and gT will work as the default behavior (switching tabs).

I agree (in my principles of deciding keymaps) that it's not good to override the default key in an agressive way, but I somehow prefer gt being goto type-definition. Personally I use [t, ]t for navigating tabs (prev tab / next tab) because it's more consistent with other motions ([c, ]c, [d, ]d, etc.) But I also wish I could use [#number]gt... Let me think about how to avoid the conflict with the default keys.

from dotfiles.

wookayin avatar wookayin commented on August 13, 2024

1gt, 2gt, 3gt, etc. would now work as well as gt (goto type definition).

from dotfiles.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.