-
-
Notifications
You must be signed in to change notification settings - Fork 139
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
:Prettier make cursor history wrong when navigating with <C-O> #48
Comments
Hi @trungdq88 thanks for reporting this issue. Will investigate this soon, otherwise feel free to submit a PR. |
I wish I could, but I have no knowledge of vim script :( |
I tested this issue with other similar formatting plugins and they all have similar problems. :( In the meantime will merge a PR that will at least mitigate this issue. You will still have to do the 2 times but the first time it wont take you to the top of the file (as the current described behavior) it will instead keep you on the same place. |
@trungdq88 closed this issue since at this stage I am not sure that I can edit vim jump history to delete the duplicate same line entry. I did however merge a PR that at least makes sure that when doing a |
That's good enough for me 👍 Thanks a lot! |
FYI: vim-go has format but it keeps the cursor position and history. You might take a look on how it achieves that. |
@mortyccp great finding! managed to find where they achieve that: and on Are examples of them deleting history, if you want to send a PR to Otherwise will see if I can squeeze sometime in to do that over the weekend |
@mitermayer Sorry, I am not familiar with VimL |
After I run
:Prettier
, and then press<C-o>
to navigate to the last position of cursor, it always point to the beginning of the file. It's annoying. Please fix this.The text was updated successfully, but these errors were encountered: