Skip to content

A simple Neovim plugin to highlight and remove trailing whitespace

Notifications You must be signed in to change notification settings

aryklein/NoTrailing.nvim

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 

Repository files navigation

NoTrailing.nvim

A simple Neovim plugin to highlight and remove trailing whitespace.

NOTE: This is just a PoC on creating a Lua Neovim plugin. You may consider to use autocmd BufWritePre * :%s/\s\+$//e instead.

Installation

-- using Lazy

{
    'aryklein/NoTrailing.nvim'
    cmd = {"TrailingTrim", "TrailingHighlightToggle"},
    config = function ()
        require('NoTrailing').setup({
            -- configuration options and defaults

            -- `highlight` configures which highlight is used to display the trailing whitespaces
            highlight = "Search",

            -- `exclude_filetypes` configures which filetypes to exclude when displaying trailing whitespaces
            exclude_filetypes = {"Telescope", "help", "lazy", "packer", "dashboard", "NvimTree", "Trouble"},
        })
    end
}

About

A simple Neovim plugin to highlight and remove trailing whitespace

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages