Closed saurabhmehta1601 closed 3 years ago
... Or just use AutoPairsDefine in an autocmd to make sure plugins have been loaded. Angle brackets have been discussed before, and they haven't been added because there's languages where these types of completions don't make sense. This includes C++ (std::cout <<
for an instance, though there are cases where it's fine. Regex-bypassable edge-case) and shell. This has been discussed before, and I can't be bothered to dig the issues and PRs up on my phone. Feel free to add it to your config, but a PR for it wouldn't be well received even if the repo was active. I've also refrained from adding it to all languages in my fork for these reasons, but I believe I hooked it up to HTML. Universal <> pair insert isn't viable or language-portable.
Yeah , totally correct . I was so focused on markdown I did'nt think about any other language . I am closing this issue now .
My problem is solved by adding \ 'html' : {"<" : ">" }
to variable allPairs
defined at line 9 in above image in same file :+1: .
@saurabhmehta1601 you can add au FileType html let b:AutoPairs = AutoPairsDefine({'<' : '>'})
to .vimrc
Since the repo does't seem too active now , instead of sending pull request I am requesting this minor addition by comment only. Support for auto closing angular brackets can be added just by adding
"<": ">"
to objectAutoPairs
in file/plugin/auto-pairs.vim
It is very helpful in html and other markdown languages , if you are not already using some plugin providing emmits.