To add automatic syntax support for open files: shiftwidth=2: number of spaces for indentation.expandtab: transforms tabs into spaces.wildmenu: shows a more advanced menu for auto-completion suggestions.ttimeoutlen=0: time in milliseconds to run commands.In this case, the screens will always split below the current screen and to the right. splitbelow splitright: changes split screen behavior with the command :split (split horizontally) and :vsplit (vertically).relativenumber: show line numbers starting from the current one.mouse=a: allows the use of the mouse in the editor.inccommand=split: show replacements in a split screen, before applying to the file.completeopt: modifies the auto-complete menu to behave more like an IDE.cursorline: highlights the current line in the editor.clipboard=unnamedplus: enables the clipboard between Vim/Neovim and other applications.Not just the background of the screen, as it might look. background=dark: apply the color set for dark screens.Here is the explanation of each command above: Set splitbelow splitright set title set ttimeoutlen = 0 set wildmenu " Tabs size set expandtab set shiftwidth = 2 set tabstop = 2 Set cursorline set hidden set inccommand = split set mouse =a Set completeopt =noinsert ,menuone ,noselect Note that in the file will have the commands that would have to be typed every time the editor opened. There are many options to tinker with, however, the ones I put below are the ones I currently use. Basic options in the configuration fileīefore we get into more complex things like extensions and their settings, let's stick to the basics. Make sure you are showing hidden files in your file manager or terminal. Remember that files starting with "." are hidden by default on Unix systems (Linux, BSDs and macOS). If these files/directories do not exist in your home folder, just create them manually. The name and location will vary depending on whether you use Vim or Neovim: To keep these settings saved, just write these commands in a file in your user folder. The problem with this is that these commands will have to be repeated each time you reopen the program. Try opening an instance of Vim/Neovim now and type :set number, you'll notice that the line numbers will appear on the side. These can be tested with the command :set. Setting optionsĪs with most software, there is a way to edit options and preferences. I'm aware that there are more modern ways to do this, but I prefer to keep my settings concise.Īt the end of this guide, you will not have a tangle of files and directories, as you may have seen elsewhere, but rather a single file, just enough for comfortable use. I have no experience with Lua, and at the moment I have no plans on learning the language just to configure the application. Here I will use the last one, as it works for both Vim and Neovim. There are two ways to configure it: using the Lua language, or VimScript, created for Vim. Neovim as is on first launch About my choices for the configurationĪs you can imagine, Neovim is configured by text files. Therefore, my configuration supports these technologies. The programming languages I use in my daily life are JavaScript (JSX and TypeScript), CSS, Sass and lately I'm studying Python, too. However, it does not come with plugins or nice looks by default. Our company has been named as one of the best Web Development Company in India.In the last few articles, I commented on why I adopted Neovim as my main editor and went through the basics for using the program. Got an Idea of Web Development? What are you still waiting for? Contact us now and see the Idea live soon. Let me know in comment if you have any questions regarding Web. I hope this blog post will help you how to Increase The Productivity by Switching to Sublime Text Editor in Web. It’s used to quickly select the next code, line, or word that has the same element as you are currently selecting. Put your cursor at starting bracket and press command + m, it’ll redirect you to ending bracket and vice versa.Ĭommand + D (Macintosh) / Ctrl + D (windows) It’s useful when you have so much stuff between the brackets.Ĭommand + M (Macintosh) / Ctrl + M (windows) Select the relevant options.īesides above mentioned points, I’d like to state few more tips and tricks which I‘ve found very useful: Command + d (Macintosh) / Ctrl + d (windows)Ĭommand + L (Macintosh) / Ctrl + L (windows)Ĭtrl + Command + M (Macintosh) / Ctrl + shift + M (windows) To enable split editing, goto View > Layout. You can edit with as many rows and columns as you wish. What if you can edit php and html files side by side? Yes, Split Editing enables you to edit files side by side.
0 Comments
Leave a Reply. |