Is there a way to add keymaps based on filetype? #2599
-
Currently I'm adding keymaps using |
Beta Was this translation helpful? Give feedback.
Answered by
MattSturgeon
Dec 2, 2024
Replies: 1 comment 1 reply
-
One approach would be to use Another approach would be to use |
Beta Was this translation helpful? Give feedback.
1 reply
Answer selected by
SymphonySimper
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
One approach would be to use
files.<filename>
instead ofextraFiles
, as that one takes a nixvim module instead of lua content.Another approach would be to use
keymapsOnEvent
to target a filetype-related autocommand event.