Giter Club home page Giter Club logo

Comments (7)

chemzqm avatar chemzqm commented on June 9, 2024 6

My advice is stick to the auto pair plugin you like, it's designed to works like VSCode, but not featured like some of others.

For improvement of <CR> it's implemented in coc.nvim to make it works with formatOnType feature of LSP, checkout :h coc#on_enter()

from coc-pairs.

voldikss avatar voldikss commented on June 9, 2024 3

@gbrlsnchs
IMO auto-pairs has a few flaws:

  • Auto indent didn't work for me sometimes when I was using auto-pairs. So I have to write vimscript by myself to meet demand.
  • auto-pairs inserts pairs always, which is a little noisy. coc-pairs just insert the first pair if the next character behind the cursor position is not a whitespace.

Maybe I didn't explain that clearly... Anyway, auto-pairs is a great plugin. πŸ˜„ Its fly-mode is fantastic, which, however, I use seldom. So after weighting and balance, I chose coc-pairs.

from coc-pairs.

gbrlsnchs avatar gbrlsnchs commented on June 9, 2024 2

Thanks, I'll definitely try it out with formatOnType, I'm loving how powerful Neovim has become thanks to coc.nvim... thanks again, mate!

from coc-pairs.

gbrlsnchs avatar gbrlsnchs commented on June 9, 2024 1

Thanks, I'll definitely try it out with formatOnType, I'm loving how powerful Neovim has become thanks to coc.nvim... thanks again, mate!

Did you find a solution? Can you post it?.

See #13 (comment) where I comment about the issue I had and how I solved it.

from coc-pairs.

cjnucette avatar cjnucette commented on June 9, 2024

Thanks, I'll definitely try it out with formatOnType, I'm loving how powerful Neovim has become thanks to coc.nvim... thanks again, mate!

Did you find a solution? Can you post it?.

from coc-pairs.

mikew avatar mikew commented on June 9, 2024

So is it possible to get proper indentation without formatOnType? Since I'm using prettier in some places, and other formatters in others, and they may not be controlled from coc, it would be nice to get proper indentation without having to resort to cocs formatting.

from coc-pairs.

chemzqm avatar chemzqm commented on June 9, 2024

So is it possible to get proper indentation without formatOnType?

Checkout :h indentexpr, formatOnType reformat current line on <CR> which means not only indentation.

from coc-pairs.

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.