Vim pasting without the weird indentation

๐Ÿ“Œ Issue

I wanted to paste the code from clipboard using vim, but when the code got longer, the formatting became super weird with a lot of tabs.


๐Ÿ“Œ Solution

It was actually really simple.

Before typing i to enter the insert mode, type :set paste.

If you go to insert mode after doing so, youโ€™ll be seeing --INSERT (paste)--. In this mode, pasing works the way you want it to!

Updated: