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

Auto delete pair & auto jump #19

Closed
kuntau opened this issue Feb 7, 2021 · 9 comments
Closed

Auto delete pair & auto jump #19

kuntau opened this issue Feb 7, 2021 · 9 comments
Labels

Comments

@kuntau
Copy link

kuntau commented Feb 7, 2021

OS : MacOS Catalina
What vim? (+ version) (i.e. vim, gvim, nvim, nvim-qt, mvim, ...): nvim HEAD
Reproduced in other variants of Vim? (Optional):

Autopairs config (if applicable):

Describe the bug

Hi, I'm new to your fork. Right away after installing I noticed some difference with jiangmiao default.

There's no configuration. Just default install with vim-plug

  1. After typing closing tag }]) it's not jumping to the closing tag instead those literal character was added.
  2. Backspace after auto insert matching tag don't delete the matching tag eg left the with )}]

Is there any settings I have to set? This is on javascript file

Steps to reproduce

@kuntau kuntau added bug Something isn't working status:Triage labels Feb 7, 2021
@LunarWatcher
Copy link
Owner

For 1: Can I get some more context? What's the opening pair like? What code are we talking about?

For 2: Mapping backspace is disabled by default in this fork

https://github.com/LunarWatcher/auto-pairs/blob/master/doc/AutoPairs.txt#L390-L398

Try let g:AutoPairsMapBS = 1 and see if that helps.

@kuntau
Copy link
Author

kuntau commented Feb 7, 2021

Please see this replay

https://asciinema.org/a/h6b1secmQthYM8fzfvrGAMXJk

on the original version, after typing ] it always jump to the end of closing ]

As is in the readme

Insert new indented line after Return

input: {|} (press <CR> at |)
output: {
    |
}          (press } to close the pair)
output: {
}|         (the inserted blank line will be deleted)

@LunarWatcher
Copy link
Owner

Something broke that, but I could've sworn I fixed that a while ago. Gonna grab some food and have a look

@LunarWatcher
Copy link
Owner

1 requires let g:AutoPairsMultilineClose = 1 - gonna change the default back to 1. (Originally changed to 0 by Krasjet)

@kuntau
Copy link
Author

kuntau commented Feb 7, 2021

1 requires let g:AutoPairsMultilineClose = 1 - gonna change the default back to 1. (Originally changed to 0 by Krasjet)

Perfect. Thank you

LunarWatcher added a commit that referenced this issue Feb 7, 2021
LunarWatcher added a commit that referenced this issue Feb 7, 2021
@LunarWatcher
Copy link
Owner

I think that should do the trick. Can you try now?

@LunarWatcher
Copy link
Owner

I'm gonna assume it's fine now. If it's still broken, reopen this issue, open a new issue, or leave a comment here

@kuntau
Copy link
Author

kuntau commented Feb 9, 2021

Hi. Thank you for the quick fix. Looks like I can't use it yet since I use the recommended Tag * 👍🏽

@LunarWatcher
Copy link
Owner

Right, just made another tag

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants