VonHeikemen / searchbox.nvim

Start your search from a more comfortable place, say the upper right corner?

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

nohl doesn't work

txtyash opened this issue · comments

Why is nohl unable to clear the searchbox highlights? Is it intended?

Current situation is:
map("n", "<C-l>", ":nohl<CR>:SearchBoxClear<CR><C-l>", { noremap = true, silent = true })

I'm using a custom highlight function. nohl can't clear that highlight group.

SearchBoxClear removes the custom highlight and then calls nohlsearch. Try using just SearchBoxClear.

 map("n", "<C-l>", ":SearchBoxClear<CR>", { noremap = true, silent = true })